I would like some clarificaiton for MarketPosition_at_Broker (for IB as broker):
1) Can it get reliable and accurate values from the Broker on every tick
2) What value will be shown when there is sudden loss of internet connection or IB(broker) has lost connection to is server farm
Regards
Super
MarketPosition_at_Broker
- JoshM
- Posts: 2195
- Joined: 20 May 2011
- Location: The Netherlands
- Has thanked: 1544 times
- Been thanked: 1565 times
- Contact:
Re: MarketPosition_at_Broker
In my experience, it's accurate, but here there is a delay of around 1-2 seconds between MultiCharts opening a position (MarketPosition(0) change) and the broker communicating the broker position change (MarketPosition_at_Broker change). (If you don't use RecalcLastBarAfter() and the market is slow, this lag is off course possibly a lot more).1) Can it get reliable and accurate values from the Broker on every tick
From the wiki page:2) What value will be shown when there is sudden loss of internet connection or IB(broker) has lost connection to is server farm
(i.e. if MarketPosition_at_Broker returns 2, and the internet connection gets lost, it will continue to return 2. And a loss of internet connection is, for MultiCharts, the same as a strategy that gets disabled manually).If Automated Trading was manually turned off by the user, the value returned by the keyword stops changing, and may remain unequal to '0'.
Re: MarketPosition_at_Broker
JoshM,
Many thanks for your feedback.
My idea was to compare MarketPosition_at_broker and Marketposition Chart before sending order out. Since I use IntrabarOrder, delay in getting values of MarketPosition_at_Broker could cause problems. I will try to incorporate your suggestion of RecalcLastBarAfter() in my code to see if it makes any difference.
Best regards
Super
Many thanks for your feedback.
My idea was to compare MarketPosition_at_broker and Marketposition Chart before sending order out. Since I use IntrabarOrder, delay in getting values of MarketPosition_at_Broker could cause problems. I will try to incorporate your suggestion of RecalcLastBarAfter() in my code to see if it makes any difference.
Best regards
Super
- Henry MultiСharts
- Posts: 9165
- Joined: 25 Aug 2011
- Has thanked: 1264 times
- Been thanked: 2957 times
Re: MarketPosition_at_Broker
It can lag behind a little on a 1 tick chart if there is more than 1 tick in a second. There should be no lag on a two second chart.
1) Can it get reliable and accurate values from the Broker on every tick