Is it better to use the shift0 and shift1, or the shift1 and shift2 to build the cross over?

To add comments, please log in or register
thomas2004
372
thomas2004  

Hi all,

Assumed the stratergy is simple. It is based on the RSI cross over. If crosses over 70 -> go short. If crosses under 30 -> go long.

My question: In this case will you use the shift1 for previous and shift0 for the current, or use the shift2 for previous and the shift1 for cirrent?

I've seen many codes and books. Some use the shift0 and shift1, but the other use shift2 and shift1.

The reason for using shift2 and the shift1 is: Since the shift0 will change tick after tick. At this tick it will cross over the threshold but in the next tick it will cross under the threshold. This will create many entry and exit signals. So it is better to use the shift2 and the shift1.

William Roeder
19817
William Roeder  

Define "better"

  1. Using current bar means you get the signal earlier and closer to the cross price.
  2. Using current bar means you may get multiple crosses as the bar forms and may get false signals if the market retreats.
To add comments, please log in or register