I have a MultiTimeframe strategy, and a condition for CrossAbove / Below.
Does the "look back period (I have 10 in my case)" applies to the BarsArray bars of the indicator (5 minutes in my case), or the BarsInProgress bars, (1 Tick in my case)?
{
AddDataSeries(Data.BarsPeriodType.Minute, 5);
AddDataSeries(Data.BarsPeriodType.Tick, 1);
}
else if (State == State.DataLoaded)
{
RSI1 = RSI(BarsArray[2], 14, 3);
}
protected override void OnBarUpdate()
(CurrentBars[0] < 15) || (CurrentBars[1] < 15) || (CurrentBars[2] < 15 && (State == State.Historical))
return;
if (BarsInProgress == 2)
{
if CrossAbove(RSI1.Default, 70 , 10)
{
do something
}
}
Comment