Hi,
can you please provide a version of the class LSModel and walk_forward in which the features used are scaled (e.g., with StandardScaler) in every training window (so, to avoid look-ahead bias)? This would be very important, especially when using exogenous variables that are on a different scale.
Thanks!
Luca
Hi Luca,
We are looking at your request and will get back to you on this.
Hi Rekhit, any update on this?
Luca
Hello Luca,
Thanks for your patience. We are still looking into it.
Hello Luca,
In the implementation of LSTM, the features were not scaled since the sign of the percentage change of closed prices of assets was used as features. However, if you are using any other features that might require scaling, then you can scale the data using StandardScaler before the features are passed to the 'calculate_weights' method of the 'Model' class in the walk_forward function.
To avoid lookahead bias, ensure only the features data till 'split' are scaled and passed as an input to the LSTM model in all iterations.
Please let us know if you have any doubts about this.