Just recently I've started to use MC's autotrading feature and I must say I'm hooked. It works great when MC manages the entire trade. What I mean is that MC initiates the buy signal and manages the sell signals without any interruptions. However what to do when MC and TWS are out of synch.
1. TWS automatically requires log out everyday. If MC is in the middle of managing a trade and TWS logs out, MC and TWS are out of synch. After I re-login, and turn autotrading back on, MC doesn't pick up managing the sell signal.
2. Can I manually initiate a trade and then turn on MC's autotrade just to manage the sell signal alone?
Here's the pseudo code for my strategy:
if (MarketPosition=0 and buySignal) then
buy next bar at X stop;
end;
if (MarketPosition=1) then
sell next bar at Y stop;
end;
Autotrading out of synch
- TJ
- Posts: 7745
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2224 times
- TJ
- Posts: 7745
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2224 times
If you are using v5 you can configure MC to assume your chart position matches your real world position at startup, and thus exit existing postions. See option "Assume the initial market position at the broker the SAME AS on the CHART".
Also see http://forum.tssupport.com/viewtopic.php?t=5441
Also see http://forum.tssupport.com/viewtopic.php?t=5441
- TJ
- Posts: 7745
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2224 times
Just noticed this at the bottom of the Help section "Working with Autotrading":
So if I have an EL signal containing two seperate long entries, and when auto trading is launched both are in the market, only one will be exited?"Auto Trading Market Position Synchronizer may not work correctly in case of Pyramiding use and if more than one active entry were generated on a chart at the moment of auto trading launch. The reason for this limitation is that dialog window is set up to define only one active entry."
- TJ
- Posts: 7745
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2224 times
thanks all for your comments.
I found the option "Assume the initial market position at the broker the SAME AS on the CHART", and so far it's working great.
I was also able to get TWSSTART working for the demo account, but not the real one. I don't really mind re-logging in if I can use "SAME AS on CHART" option.
I found the option "Assume the initial market position at the broker the SAME AS on the CHART", and so far it's working great.
I was also able to get TWSSTART working for the demo account, but not the real one. I don't really mind re-logging in if I can use "SAME AS on CHART" option.
- TJ
- Posts: 7745
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2224 times
google for TSSTART to prevent TWS from logging off.
Read my original post again.With real/funded IB Account you have to key in the security number generated by their logging device, how would TWSStart handle that issue.Not correct.TWSSTART will only work with Demo or Simulated account.
Will appreciate your views.
Regards
Super
Presumably your either trading or SIM trading STOCK rather than FX with IB?
I'm interested to know because I have spent a considerable time over the Christmas break trying to reconcile symbol setups and autotrading fx to IB with no success. Both Marina, Stefan and this forum have tried to assist but Marina has pointed out there is likely a bug in the config of the beta for fx symbols. So if anyone out there is successfully autotrading fx to IB please share your setup?
Thanks.
{the error is that inherited fx symbols from IB do not have correct settings for standard one lot order of 100,000 leaving either backtest and chart incorrect or order size incorrect resulting in rejected orders from IB SIM - either problem kills simulation}
I'm interested to know because I have spent a considerable time over the Christmas break trying to reconcile symbol setups and autotrading fx to IB with no success. Both Marina, Stefan and this forum have tried to assist but Marina has pointed out there is likely a bug in the config of the beta for fx symbols. So if anyone out there is successfully autotrading fx to IB please share your setup?
Thanks.
{the error is that inherited fx symbols from IB do not have correct settings for standard one lot order of 100,000 leaving either backtest and chart incorrect or order size incorrect resulting in rejected orders from IB SIM - either problem kills simulation}