Course Name: Deep Reinforcement Learning in Trading, Section No: 11, Unit No: 11, Unit type: Notebook
The lookback period for the indicators were all non-default for the specific technical indicator and also adjusted from the game class default. Why?
I think the -1 is to prevent lookahead, but I don't think that would be an issue if the time index is at the close of the bar. But the period for the Aroon Oscillator is reduced -3; Why? Thanks in advance.
Hello Edgar,
As you might have noticed, the length of the data 'last5m' is equal to 'lkbk' which is 20.
The timeperiod for technical indicators with rolling calculations should be less than the size of the input data. Hence for technical indicators like sma1, RSI, and momentum, we used 'lkbk-1' as timeperiod for calculating these technical indicators.
Similarly, the timeperiod for the Aroon oscillator should be less than the length of the input data i.e. lkbk. So, you can use 'lkbk-1' or 'lkbk-2' or 'lkbk-3' etc.
Since we have used 'lkbk-1' for other indicators, we used 'lkbk-3' for the Aroon indicator just to generate indicator values for a timeperiod other than 'lkbk-1'.
You can also tweak the timeperiod of the Aroon indicator by using 'lkbk-2' as the timeperiod.
Hope this helps!