SA mode: how to inherit an open trade?

Questions about MultiCharts and user contributed studies.
wilkinsw
Posts: 662
Joined: 21 Apr 2013
Has thanked: 154 times
Been thanked: 104 times

SA mode: how to inherit an open trade?

Postby wilkinsw » 22 Apr 2020

Hi,

If trading in SA mode and for some reason I have to turn live trading off then back on again, with an open position, I always switch to AA mode otherwise I can't get the live trading chart to inherit the open position and send the correct exit orders.

Is this what other users do?

If i turn auto trading back on in SA mode, it doesn't matter what I specify on the window that pops up (if i tell it that I'm in a trade) it won't send orders that correspond to the open trade (it won't inherit the trade, it will just send new entry orders).

Can anyone help me out here? How do you make a signal in SA mode inherit an open trade when toggling auto trading off/on?

Thanks!

Will

Mydesign
Posts: 177
Joined: 15 Feb 2017
Has thanked: 32 times
Been thanked: 39 times

Re: SA mode: how to inherit an open trade?

Postby Mydesign » 22 Apr 2020

Hi wilkinsw,

Try to add the following signal: !From Broker to Strategy MP Synchronizer!

wilkinsw
Posts: 662
Joined: 21 Apr 2013
Has thanked: 154 times
Been thanked: 104 times

Re: SA mode: how to inherit an open trade?

Postby wilkinsw » 22 Apr 2020

Thanks.

If i've got two live charts mapped to the same account and both have long positions (different prices and different entry bars); when turning auto trading (SA) off then on again how do I use !From Broker to Strategy MP Synchronizer! to get the charts to inherit the correct trades inclusive of respective entry price, bar and lots?

Is it even possible?


kagein
Posts: 55
Joined: 12 Oct 2017
Has thanked: 16 times
Been thanked: 10 times

Re: SA mode: how to inherit an open trade?

Postby kagein » 23 Apr 2020

This is what i do all the time.. Ive tried using the MP sync, but when you have multiple signals trading the same contract in the same account, it just ends up sending the wrong size orders. Ive found its easier to do it manually. ie changing the chart to AA. If an automatic solution can be found that would be a great help.

Mydesign
Posts: 177
Joined: 15 Feb 2017
Has thanked: 32 times
Been thanked: 39 times

Re: SA mode: how to inherit an open trade?

Postby Mydesign » 24 Apr 2020

Same here. I cannot get perfect sync when trading several charts on the same instrument. And it gets worse when switching Off/On the autotrading. I manage it myself, and do not use the !Broker to Strategy! signal in this case.

There is no way for MC to know from which strategy belong what quantity. And on the broker side it is the same, usually with a FIFO logic, whichever chart actually sent the order.

User avatar
Anna MultiCharts
Posts: 560
Joined: 14 Jul 2017
Has thanked: 42 times
Been thanked: 140 times

Re: SA mode: how to inherit an open trade?

Postby Anna MultiCharts » 01 May 2020

Hi everyone,

There was a similar discussion here. Please check this thread.

janus
Posts: 835
Joined: 25 May 2009
Has thanked: 63 times
Been thanked: 104 times

Re: SA mode: how to inherit an open trade?

Postby janus » 01 May 2020

I've struggled with the same issues (and other related ones) for years. I've resigned to the fact that the only way to be absolutely certain about it all is to write code that uses the id's of the trades that are returned back from the broker (in my case IB). If necessary one would need to write an API to extract the information directly from the broker. Then keep a record of them on the computer such that the next time MC is started it picks up the information and handles the trades accordingly in the study. It's a lot of work but it would be possible. I started working on such an approach some time ago but never finished it as I had other more jobs to do with trading in MC. I already have developed code in Python for a CFD provider to extract the trade information at any time. So I'm sure I could do the same for IB. MC could be designed to do all that built-in. I'm not sure if such a request has been posted. If not it would be worth doing so.


Return to “MultiCharts”