Hi, the behaviour you observe is the same how it is done by brokers like IB. If you set a trailing stop it is updated in real-time during the current day, and stop will be triggered immediately when the market moves back in direction to your stop.
Regards, Markus --- In [email protected], "olivier_molongo" <[EMAIL PROTECTED]> wrote: > > Hi, > > It seems that trailing stops are 'trailed' on the current bar. this > is wrong. The trailing stop should be calculated on the previous bar > and should be fixed on the current bar. Otherwise a trailing stop for > a long position is activated on a day the market is going up a lot > which is an incorrect behaviour. > > I use this code : > > Buy = UpIndic ; > Sell=0; > ApplyStop( 2, 2, TrailStopAmountUp, 1,True ); > > The problem is that for TrailingStops AB uses the high of the day to > set the stop. So when using > > ExitAtStop = 1 - check High-Low prices and exit intraday on price > equal to stop level on the same bar when stop was triggered > > one get stoped out incorrectly on an up day when the net change for > the day is more that the trailingstop amount. That is not a logical > behaviour. The trailing stop for the day should be defined using the > highest high since the buy but without including the current day. > > I can't get this to work even when using a volatile trailing amount > as it seems that the trailing stop is calculated on the day before > the current bar but trailed on the current bar. It should not be > trailed on the current bar. It should remain fixe on the current bar > and trailed on the next day. > > Can you fixe that or is there a workaround for this? > > Regards, > Olivier >
