darts icon indicating copy to clipboard operation
darts copied to clipboard

Sliding Window Backtest

Open ajayganti3 opened this issue 4 years ago • 3 comments

In Backtest we have 2 strategies named Expanding window and Sliding Window. As per my understanding currently Darts support Expanding window backtest. If Sliding window backtest is implemented as a new feature, then it would be really helpful because expanding window backtest over a 100K timeseries would be too much of compute intensive when compared to Sliding window backtest. Sliding window visual representation is given in the below image.

image

ajayganti3 avatar Aug 03 '21 03:08 ajayganti3

Hi @ajayganti3, thanks for your suggestion, this addition is definitely on our radar! For now, to speed-up your backtesting, you can also consider setting retrain=False in case you are using TorchForecastingModel instances. You can also increase the stride parameter for some linear speed-ups. But a sliding window would definitely be nice, we agree. Please stay tuned!

pennfranc avatar Aug 05 '21 11:08 pennfranc

Any news here regarding this feature? It would be really nice if you could add this.

pabuta88 avatar Dec 08 '21 10:12 pabuta88

Hi @pabuta88, you can set the parameter train_length and then the moving window strategy is used. Quoting the documentation: "Default is set to train_length=None where it takes all available time steps up until prediction time, otherwise the moving window strategy is used" (source: StatsForecastAutoARIMA documentation)

shagn avatar May 25 '22 13:05 shagn

Closing as this is now implemented.

hrzn avatar Jan 05 '23 10:01 hrzn