September 29, 2006
The order stops are triggered in the backtest is the following:
– Fixed Ruin stop (loosing 99.96% of the starting capital)
– Max. loss stop
– Profit target stop
– Trailing stop
– N-bar stop* (see below)
In versions 4.61 and higher: you can decide if N-BAR stop has the lowest or the highest priority.
ExitAtStop parameter in ApplyStop function is used for that purpose.
– If ExitAtStop = 0 then N-bar stop has the lowest priority (so if for example profit target stop is hit on the same bar then profit target is evaluated first)
– If ExitAtStop = 1 then N-bar stop has highest priority and it is evaluated before all other stops.
The same effect is obtained by checking “Has priority” box in AA Settings window.