This notebook applies a previously selected ETF configuration to its reserved holdout window. It derives the matching holdout predictions from the selected training identity and checkpoint, then uses the strategy's existing concentration, allocation, risk…
Knowledge library
Summaries and key ideas, written by Stratmill's research agent, of the books, papers, articles and code our AI agents read. Each page links to its original.
Search the library
566 documents
This evaluation workflow screens financial and model-based features against forward returns for a NASDAQ-100 intraday panel. It first reserves the final test period, excluding observations whose forward labels would settle within that window. For each…
This document describes a daily US equities dataset sourced from NASDAQ Data Link’s Wiki Prices archive. It covers thousands of companies from 1962 through March 2018 and includes delisted firms, making it useful for historical research that needs to reduce…
This document explains how to measure returns around events such as signal triggers, earnings announcements, or macro releases. Its worked example uses momentum breakouts in liquid ETFs. For each event, a market model fitted to a pre-event estimation window…
This notebook presents an unconditional Sig-Wasserstein GAN for generating financial time series. It replaces a learned real-versus-generated discriminator with a distance based on expected path signatures, mathematical summaries of a path’s sequential…
This notebook uses daily ETF returns to explain how GARCH models capture volatility clustering and turn it into a session-by-session feature. It first uses visual diagnostics and an ARCH-LM test to assess whether squared returns depend on their own lags. A…
This notebook explains how to rebuild a single-symbol NASDAQ limit order book from message-by-order data. It processes adds, executions, cancellations, deletes, and replacements while maintaining the remaining size of each live order. Replacements require…
This source module provides loaders for U.S. equity prices, index data, options, market microstructure, fundamentals, and institutional holdings. Its most substantive methodological detail concerns resampling intraday trade data: open, high, low, close, and…
This notebook demonstrates a shared OHLCV interface across Yahoo Finance, a long-history U.S. equity archive, and FRED macroeconomic series. It builds an ETF universe for a later rotation case study, shows how to combine historical and current sources, and…
This case study builds features for researching whether at-the-money implied variance exceeds subsequent realized variance for S&P 500 names, and whether the difference varies across securities. It combines straddle quotes with underlying prices to measure…
This notebook compares ordinary least squares with Ridge, LASSO, and Elastic Net for predicting forward returns across an ETF universe. All models use the same walk-forward folds, with a purge gap matched to the label horizon, so differences can be…
This chapter outlines how to build time-consistent fundamentals and alternative-data research across equities, macroeconomic series, futures, crypto, and prediction markets. Its central methods are bitemporal storage and as-of queries, source-aware…
This notebook reprices leading ETF allocation configurations across two cost grids while holding predictions, concentration, and allocation rules fixed. It compares the case study's per-share commission and half-spread model, which reflects how ETF trading…
This notebook uses principal component analysis on a liquid subset of US stocks to build gross-normalized eigenportfolios and study their role as latent risk factors. It examines explained variance, interprets components through sector ETF correlations,…
This notebook compares linear models for predicting ETF returns from overlapping price-derived features. Since multiple return horizons and indicator families can encode similar information, ordinary least squares may assign unstable opposing coefficients to…
This configuration describes monthly long-short US equity portfolios ranked on firm characteristics. It specifies a complete-case universe with 46 characteristics, month-end decisions, next-open execution, equal weighting within the long and short legs, and…
This guide maps causal questions to Python libraries and clarifies the distinction between estimating effects under an assumed causal structure and discovering possible structures from data. It introduces double machine learning for adjusted treatment…
This framework demonstrates data-quality checks on daily US equity OHLCV data. Structural validation tests price relationships, positive prices, nonnegative volume, missing values, duplicate dates, chronological order, stale prices, and extreme returns. The…
This notebook introduces a stochastic discount factor model for pricing a cross-section of ETFs. Instead of separately estimating fund exposures and factor returns, it trains networks to find a common discount-factor series whose covariation with fund…
This notebook reconstructs the prevailing best bid and offer for each AAPL trade during a single March 2020 session, then applies the Lee–Ready method to infer whether buyers or sellers initiated trades. It interleaves quote and trade events in timestamp…
This notebook screens financial and model-derived features for their ability to rank ETFs by subsequent returns. It calculates a date-by-date information coefficient by comparing each feature’s cross-sectional ranks with forward-return ranks, then examines…
This notebook examines whether SHAP feature attributions are stable enough to support model pruning, risk decisions, or reporting. Using an ETF prediction task, it first searches for test samples whose predictions are close while their SHAP profiles differ.…
This configuration describes a daily, long-short US equity strategy that ranks a broad stock universe by model predictions, buys the top decile, and shorts the bottom decile with equal weights within each group. It specifies next-session open execution,…
This data utility supports work with the Chen, Pelger, and Zhu asset-pricing dataset, which includes stock returns, firm characteristics, macroeconomic series, and pre-split characteristic tensors. Its conversion method builds Parquet files from the…