Day 208 — The relationship you fitted may not be the same one
Tuesday, 2 March 2027 · Week 30 of 52 · Machine learning · Study day · 60 min
Non-stationarity is the failure mode that no cross-validation scheme catches, because every scheme assumes the thing being estimated is the same thing throughout.
What you should be able to do tonight
- Report how much your fitted relationship varies across eras, and say whether that variation is larger than estimation error.
- Say what a model should do about non-stationarity, and why the obvious answer of a shorter window has a cost you can quantify.
Tasks 60 min
30 min Test formally rather than by eye: for each coefficient, compare the across-era variance against the within-era standard errors. If the first exceeds the second, the relationship is genuinely moving and a single fitted model is estimating an average of different things.
30 min Quantify the window trade-off: fit the model on rolling windows from 1 to 10 years and plot the out-of-sample R-squared against window length. A short window adapts and has more estimation error; a long window is stable and stale. The maximum of that curve is your answer and it is a measurement rather than a preference.
Resources
Deliverable
notebooks/day-208-nonstationarity.ipynb with across-era coefficient variance against within-era standard errors, and R-squared plotted against training window length.
Checkpoint
Your value coefficient is positive in three eras and negative in one. Is that non-stationarity or noise, and what test told you?
Prepare for tomorrow
Ten minutes tonight so Day 209, Wednesday, 3 March 2027 starts clean. This is what the evening email sends you.
Assemble your eight signals into a feature matrix aligned with forward returns, with the point-in-time rules from phase 5 respected.
Check the row count and the fraction of missing values per feature.
Save it. It is the input for the next four weeks.