Collections
Curated reading paths through the blog, ordered from basics to advanced.
Backtesting Without Fooling Yourself
A step-by-step path from what your backtest really optimizes to proving an edge survives overfitting, multiple testing, and live execution. Read top to bottom — each part builds on the last.
- 01Objective-Function Design: The Metric You Optimize Secretly Picks Your Strategy
- 02Proving No Look-Ahead in Multi-Timeframe Backtests: Perturb the Future, Prove the Past Can't See It
- 03Look-Ahead Bias: How a One-Bar Mistake Manufactures a Sharpe of 15 From Pure Noise
- 04Walk-Forward Optimization: The Only Honest Strategy Test
- +7 more
High-Performance Backtest Engines
How to build a backtest engine that runs hundreds of times faster without changing a single PnL number — data layout, caching, adaptive resolution, and architecture, from first speedups to production internals.
- 01The Backtest Speed Ladder: 298x on a Laptop CPU, Identical PnL to the Last Trade
- 02The Framework Tax: When Your Backtest Library Is Slower Than a Naive Pandas Loop
- 03Aggregated Parquet Cache: How to Speed Up Multi-Timeframe Backtests by Hundreds of Times
- 04The Two-Axis Parameter Space: Why Most of Your Sweep Should Be Nearly Free
- +7 more
Complex Arbitrage in Rust
A six-part build-up of multi-leg crypto arbitrage — from negative-cycle detection to the linear algebra, copulas, and machine learning behind it, ending in low-latency Rust execution.
- 01Graph Algorithms for Arbitrage Detection: From Bellman-Ford to RICH
- 02Futures-Spot Arbitrage: From Cash-and-Carry to DeFi-CeFi
- 03Matrices, Tensors, and Tropical Algebra: Linear Algebra for Arbitrage Detection
- 04Vine Copulas for Arbitrage: Modeling High-Dimensional Dependencies
- +2 more
Order Book & Market Microstructure
How the order book really works — accessing the data, reading queue position, rebuilding bars from order flow, and modeling it with deep learning and Hawkes processes.
- 01CCXT: How WebSocket Orderbook Methods Really Work
- 02Order Types in Algorithmic Trading: From Limit with Chasing to Virtual Orders
- 03Queue Inside the Wall: Analyzing Order Position in Order Book Density
- 04Bar Types and Aggregation Methods for Algorithmic Trading
- +8 more
Portfolio Construction & Risk
From Markowitz to production HRP + CVaR: how to allocate across crypto assets, model tail dependence with copulas, and size positions without blowing up.
- 01Markowitz Portfolio Theory for Crypto: From Zero to Hero
- 0212 Portfolio Optimization Algorithms, Compared: HRP, Black-Litterman, NCO and Beyond
- 03Inside Our House Algorithm: HRP + Long/Short + CVaR with Hull-White
- 04Copula Models for Joint Risk Modeling in Crypto Portfolios
- +1 more
Risk & Position Sizing
Build position sizes from drawdown math, realistic trading costs, and uncertainty in backtest results before applying Kelly.
- 01Loss-Profit Asymmetry: The Math That Kills Your Deposit
- 02Slippage curves, not slippage constants: cost models that survive contact with live trading
- 03Monte Carlo Bootstrap: How to Get Confidence Intervals for a Backtest in 10 Lines of Code
- 04The Kelly Criterion for Strategies: How to Size Positions and Allocate Capital
Statistical Arbitrage & Pairs Trading
Trade the spread between correlated assets — from the distance approach to cointegration and Kalman filters, then dynamically combining mean reversion with momentum.
- 01Distance Approach in Pairs Trading: Implementation and Analysis with Rust
- 02Statistical Arbitrage and Pairs Trading in Crypto Markets: From Cointegration to the Kalman Filter
- 03Signal Correlation: How Many Pairs to Monitor
- 04Dynamically Combining Mean Reversion and Momentum Strategies in Statistical Arbitrage: Mathematical Foundations and Practical Implementation
- +1 more
Deep Learning for Markets
Neural forecasting for crypto — transformers, diffusion models, and foundation models, and how conformal prediction keeps their uncertainty honest.
- 01Temporal Fusion Transformers for Multi-Horizon Portfolio Forecasting
- 02Diffusion Models vs Cryptocurrency Anarchy: Why DDPM Can Predict Bitcoin Crashes Better Than Your Astrologist
- 03Kronos: A Foundation Model That Teaches Candlestick Charts to Speak Transformer Language
- 04Conformal Prediction for Risk-Aware Position Sizing
AI Agents for Trading
The agentic-AI stack for markets — multi-agent frameworks, open-source hedge funds, and LLMs that mine alpha from earnings calls.
- 01Revolution in Investment Portfolio Management with Agentic AI
- 02TradingAgents: Multi-Agent AI Framework That Models a Hedge Fund
- 03AI4Finance Foundation: The FinGPT, FinRL, and FinRobot Ecosystem for Algo-Trading
- 04AI Hedge Fund: A Multi-Agent Fund Where AI Analysts Vote on Trades
- +1 more
QuestDB for Algorithmic Trading
Stand up a time-series stack for trading on QuestDB — from architecture to the SQL that matters, to a production deployment.
- 01QuestDB for Algorithmic Trading: Architecture That Speaks the Language of Markets
- 02QuestDB for Algorithmic Trading: SQL Extensions That Change the Game
- 03QuestDB for Algorithmic Trading: From Order Books to Production Architecture
Low-Latency Trading Infrastructure
The plumbing under an HFT stack — how components talk (WebSocket, FIX, gRPC, Aeron), messaging on Aeron and Zig, and a C++ FIX/FAST scalper.
- 01Data Communication in Algo Trading Systems: A Technology Overview
- 02Aeron: Inside the Messaging System That Powers Half of the HFT Industry
- 03ZigBolt: Why We Built Our Own Aeron in Zig and Hit 20 Nanoseconds Per Message
- 04Developing a Simple C++ Scalper Using FAST/FIX: Step-by-Step Guide
Execution & Market Making
From TWAP/VWAP and Almgren-Chriss to TCA, slippage models, and the Avellaneda-Stoikov market maker — how to turn a signal into fills without paying the spread twice.
- 01TWAP vs VWAP vs POV: picking an execution benchmark (and knowing when each lies to you)
- 02Almgren-Chriss Without the Hand-Waving: Optimal Execution You Can Implement in an Afternoon
- 03Inside the slice: child-order tactics between your scheduler and the exchange
- 04Smart Order Routing in Crypto: One Order, Twelve Venues, No NBBO
- +7 more
Onchain & DeFi Quant
Quantitative DeFi from first principles — MEV and sandwich attacks, atomic arbitrage, liquidation cascades on lending protocols, and LP profitability on Uniswap v3.
- 01MEV anatomy: sandwiches, frontrunning, and the dark forest of the mempool
- 02The MEV supply chain: PBS, MEV-Boost, and who actually captures the value
- 03On-chain arbitrage: atomic cycles, flash loans, and the auction you have to win
- 04Liquidations on-chain: Aave and Compound mechanics, and the bot business around them
- +5 more
Causality & Lead-Lag in Markets
Who moves whom — Granger causality, transfer entropy, PCMCI discovery, and the causal ML toolbox (double ML, causal forests, synthetic control) applied to crypto markets.
- 01Toda-Yamamoto vs Differenced Granger: Does the BTC Lead-Lag Survive?
- 02Transfer Entropy: Which Way Does Information Flow Between Crypto Assets?
- 03PCMCI: Causal Discovery in Multivariate Crypto Time Series
- 04Causal Forests for Heterogeneous Treatment Effects in Trading
- +3 more
Volatility Modeling & Regimes
Forecast volatility with the GARCH family — asymmetry and leverage effects, dynamic correlations, vol targeting — then detect market regimes with HMMs and trade adaptively.
- 01GARCH(1,1): Forecasting Crypto Volatility
- 02Asymmetric and Heavy-Tailed GARCH: EGARCH, GJR, and Student-t
- 03DCC-GARCH: Dynamic Correlations for Pairs and Portfolio Risk
- 04Volatility Targeting and Trading with GARCH Forecasts
- +1 more
Modern ML for Trading
The full gradient-boosting-to-neural-operator toolkit — ensembles, AutoML, probabilistic forecasting, distillation and pruning for latency, plus physics-informed architectures like Neural ODEs and Fourier operators.
- 01XGBoost for Return Direction: Class Imbalance and Decision Thresholds
- 02Ensemble Methods: Combining Weak Learners for Robust Alpha
- 03AutoML for Systematic Trading Pipelines
- 04Multi-Task Learning for Simultaneous Price, Volume, and Volatility Prediction
- +11 more