Accuracy & evaluation
Walk-forward validation
Also called rolling origin, time series cross-validation
Walk-forward validation is backtesting that respects time: train on the past, predict the next horizon, slide the origin forward, repeat. You never train on a Wednesday to predict the Tuesday before it.
Random k-fold is the wrong tool. Time has an arrow. Mix the folds and you will ship a model that already saw the 'future.'
You can expand the training window (more history each fold) or slide a fixed window (forget the distant past). Expanding is common. Sliding helps when old regimes poison the fit.
Purge a small gap between train and test if your features are slow to settle (late-arriving sales). Otherwise the last training day leaks into the first test day through a rolling statistic.
History · origin · horizon