TrailingStart and TrailingStep can either be different or equal, it’s up to you.
I think the problem is accumulating positions, as TRADEPRICE is an average af the entry price of all positions, so it will change as any single positions is added.
Sorry guys, Nicolas just reminded me that POSITIONPRICE is the average price of all open positions, while TRADEPRICE is the last price traded. This will not affect the above code, though.
Have you came up with a solution of this? I dont have the same trialingstop code but it happend to me today. I put the example here, the stop went from minus 200 to minus 20 when the price went up. The price went up a little more and the stop came down to minus 40. Is this a bug? I cant really say its a problem with the code.
By watching my code I think that if the trailingstops kicks in on the wrong side of the entry position the trailingstop will continue the wrong way.
BUT my question is why is trailing stop going on the wrong side as it should secure a “win”
I haven’t noticed this problem for a while now. I think it has something to do with the TS being in conflict with the IG minimum stop distance.
Hmm okay.. But lets say this happens “attached picture” (trailing stopp kicked in on wrong side of entry)
And the price move up (ath) will the stop move up or down? I mean if it moves up its completly fine but Im scared it wont?
what TS code are you using?