v3.0.0-alpha.3 — Part II: Research Design and Feature Engineering
Pre-releasePart II is live. These five chapters sit between the data layer (Part I) and the model chapters: they define the trading problem, then turn validated data into model-ready signals — labels, features, and the evaluation that determines what any model can learn.
The code is rolled out in batches over the coming weeks, toward the full launch in July, in book order so every link resolves and the repo stays coherent at each step.
What's here
- Part II — Research Design and Feature Engineering (Chapters 6–10), with READMEs and paired Jupytext notebooks (43 notebooks):
- 6. Strategy Research Framework — defining the trading game before building models: universe rules, decision schedule, cost model, evaluation protocol, and the walk-forward cross-validation discipline that anchors Chapters 7–20.
- 7. Defining the Learning Task — label engineering (forward returns, triple-barrier, trend scanning), information-coefficient inference, multiple-testing control, and causal plausibility checks.
- 8. Financial Feature Engineering — price, volume, microstructure, structural, cross-instrument, and contextual features, with feature selection and robustness testing.
- 9. Model-Based Feature Extraction — features from fitted models: stationarity, structural breaks, fractional differencing, Kalman filters, spectral features, GARCH volatility, and HMM regimes.
- 10. Text Feature Engineering — from bag-of-words to transformers: embeddings, FinBERT sentiment, financial NER, and news-return signal construction.
- The shared
case_studies/utils/package the feature notebooks build on.
Get started
git clone https://github.com/stefan-jansen/machine-learning-for-trading.git
cd machine-learning-for-trading
cp .env.example .env
docker compose pull ml4t # or: pip install uv && uv sync
uv run python data/download_all.py --free-only
uv run python 06_strategy_definition/01_cv_foundations.pyWhat's next
Part III (model development, Chapters 11–15) follows, then the rest in book order. ⭐ Watch or star the repo to follow along, and subscribe to the twice-weekly Insights newsletter.
Live cohort course
Machine Learning for Trading: From Research to Production starts Monday, July 6, 2026 — enrollment for the first cohort closes Friday, July 3. Recordings of the June 24 lightning lessons are still available: Build Multi-Agent Systems You Can Audit and From Trading Idea to Validated Strategy.
Looking for the second edition? It is complete and stable on the second-edition branch — git checkout second-edition.
This is a pre-release. The complete third edition will ship as v3.0.0.