Connect to IBKR with Python
This post shows how to connect Python to Interactive Brokers with ib_async and download historical prices into pandas.
Backtests, data, and equity strategy ideas. Code when relevant.
This post shows how to connect Python to Interactive Brokers with ib_async and download historical prices into pandas.
When an outcome spans several future observations, training labels can overlap the test period. This post shows how purging that overlap removes the inflated accuracy.
This post shows how bootstrapping can reduce uncertainty about whether the performance of backtested trading strategies reflects a genuine edge or chance.
Download trade and quote data from LSEG Tick History using Python, with chunked requests, automatic retries and resumable CSV exports.
Two unrelated series can appear highly correlated, even when there is no real relationship between them.
Five rules for focusing your writing and saying more with less.
A walk-forward test of the chess rating system on four World Cups.
A set of short Python lines to backtest a strategy.
Three portfolios' performance across the full range of S&P 500 monthly returns, 1988 to 2026.
Using Detection-Controlled Estimation to recover hidden market crimes from observed prosecutions.
A monthly-rebalanced, equal-weighted portfolio of the top 30 highest-yielding US stocks benchmarked against the S&P 500.
One-week S&P 500 total-return outcomes after large single-day moves, 1988 to 2026.
A monthly-rebalanced, equal-weighted portfolio of the largest net-dollar insider buyers benchmarking against the S&P 500.
Classifying insiders as informed according to Cohen, Malloy & Pomorski (2012) routine/opportunistic insider split.
A copy-paste pipeline for pulling every Swedish stock since 2000, active and delisted, into one CSV.