Skip to content

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.

Quant Q&A
20,364 documents
SuperMind
12,226 documents
OKX Learn
8,431 documents
Strategy library
7,910 documents
MQL5 code base
7,090 documents
BigQuant
3,481 documents
Bitget Academy
3,298 documents
MQL5 articles
3,012 documents
TradingView scripts
1,976 documents
ProRealCode
1,507 documents
Deribit Insights
1,232 documents
Machine Learning for Trading
1,124 documents
arXiv papers
1,033 documents
Amberdata research
766 documents
FMZ forum
682 documents
FMZ digest
662 documents
vn.py community
560 documents
QuantInsti blog
511 documents
Galaxy Research
340 documents
QuantStart
246 documents
Stratmill research code
219 documents
Robot Wealth
195 documents
NautilusTrader
191 documents
Hummingbot docs
181 documents
Paradigm research
175 documents
Lumibot
164 documents
Kraken Learn
163 documents
Quant course library
157 documents
OctoBot
152 documents
Cryptohopper blog
144 documents
Systematic trading blog (Rob Carver)
132 documents
Qlib
116 documents
TqSdk
86 documents
Quantpedia
86 documents
Hyperliquid docs
79 documents
Freqtrade
68 documents
Hudson & Thames
62 documents
Awesome Systematic Trading
61 documents
backtrader
54 documents
vn.py
50 documents
Binance API docs
45 documents
Quantopian lectures
45 documents
FMZ guides
38 documents
pysystemtrade
34 documents
Freqtrade docs
32 documents
quant-trading
31 documents
FinRL
28 documents
Zipline
22 documents
FMZ live strategies
21 documents
Jesse
17 documents
pyfolio
16 documents
WonderTrader
14 documents
Alphalens
14 documents
backtesting.py
11 documents
Technical Analysis
9 documents
QTPyLib
8 documents
QuantRocket
7 documents
Lumibot strategies
7 documents
Awesome Quant
1 documents

Search the library

765 documents

MQL5 code base

This expert advisor compares the overlaid price histories of two currency pairs and trades when their divergence retreats from a recent maximum. It starts from a chosen point, scales the second pair’s price range to roughly match the chart pair, and measures…

ForexPairs tradingMean reversionBacktesting
Stratmill research code

This documentation describes a simulator for autoregressive series and pairs whose cointegration error follows an AR(1) process. One series is modeled through its changes, while a linear combination of the two series represents the spread or cointegration…

Pairs tradingStatisticsBacktesting
Stratmill research code

The Pearson approach forms equity pairs by ranking stocks on the correlation of their monthly returns during a formation period. For each stock, it selects the most highly correlated peers and combines their returns into a benchmark portfolio, using either…

EquitiesPairs tradingArbitrageStatistics
Stratmill research code

The time series approach begins after a pair or group of assets has already been selected, for example through cointegration testing. It models the resulting spread to produce trading signals, shifting the focus from finding related securities to deciding…

Pairs tradingStatisticsMean reversion
MQL5 code base

This indicator plots the price difference between two chosen trading symbols, with AUDUSD and NZDUSD given as defaults. Each symbol has a weight parameter, allowing the displayed spread to reflect a weighted difference rather than only an unadjusted…

ForexPairs tradingMarket microstructureTechnical indicators
Stratmill research code

This module describes selecting three partner stocks for each target in a four-stock vine-copula statistical arbitrage framework. It compares four approaches using ranked daily returns: a baseline that sums pairwise Spearman correlations, a multivariate…

EquitiesPairs tradingArbitrageStatistics
Stratmill research code

This module describes a method for selecting upper and lower trading thresholds for a mean-reverting cointegration pair. It estimates a hedge ratio using either Engle–Granger or Johansen analysis, constructs the cointegration error as the spread, and fits an…

Pairs tradingMean reversionStatisticsRisk management
Stratmill research code

This implementation describes a distance-based statistical arbitrage method for forming and trading equity pairs. In a training period, each price series is scaled using its own minimum and maximum, and candidate pairs are ranked by the sum of squared…

EquitiesPairs tradingArbitrageMean reversion
Stratmill research code

This document extends a cointegration-based spread strategy from pairs to three or more assets. It forms a weighted combination of log prices using a cointegration vector, then derives a spread return from the same weights. Under stated stationarity…

Multi-assetMean reversionPairs tradingPortfolio construction
vn.py

This example demonstrates a portfolio-strategy backtest for a pair trading strategy on two Dalian Commodity Exchange continuous contracts. It configures minute data over a specified historical interval and supplies commission rates, slippage, contract sizes,…

FuturesPairs tradingBacktestingExecution
BigQuant

The study applies machine learning to estimate an optimal rebalancing frequency for pairs trading. It uses minute-level prices for 50 large cryptocurrencies from Binance during 2022 and 2023. For each asset pair, a simulated pairs-trading algorithm…

CryptoPairs tradingMachine learningPortfolio construction
vn.py community

A forum exchange addresses how to monitor current account profit or obtain opening fill prices inside a spread trading strategy. The question notes that the spread-trading forum’s trade callback cannot be called directly from the strategy, and asks for…

FuturesPairs tradingExecution
Stratmill research code

This documentation describes a function for estimating the half-life of a mean-reverting process under an Ornstein-Uhlenbeck assumption. The model represents changes in a variable as a pull toward a level, plus Gaussian noise. The half-life is a way to…

Mean reversionStatisticsPairs trading
Stratmill research code

This implementation describes an equity pairs strategy that selects stocks with highly correlated historical returns, then compares each stock’s return with a portfolio of its selected peers. It estimates a regression coefficient during a formation period…

EquitiesPairs tradingMean reversionStatistics
SuperMind

The document explains statistical pairs trading as a market-neutral mean-reversion approach. It describes selecting two securities with historically similar price behavior, then selling the relatively expensive leg and buying the relatively cheap leg when…

Pairs tradingMean reversionArbitrageTechnical indicators
MQL5 code base

The document describes an indicator intended to plot cumulative profit and loss for configured spread or equity positions as an equity line in a chart subwindow. Users set each active pair’s volume, direction, and activation state, can provide a symbol…

EquitiesPairs tradingBacktestingRisk management
SuperMind

This code implements a bivariate mixture of Clayton, Frank, and Gumbel copulas, framed as a dependency model for a mixed-copula pairs trading strategy. It transforms each input series to empirical marginal quantiles, then fits the mixture weights and…

Pairs tradingStatisticsMachine learningBacktesting
MQL5 code base

This broad guide surveys algorithmic trading approaches, including momentum, statistical arbitrage and pairs trading, market making, machine learning, and options. It outlines how each approach seeks opportunities: following trends, trading relative-price…

MomentumArbitragePairs tradingMarket making
Stratmill research code

This module generates synthetic pairs whose relationship is defined by a hedge ratio and a mean-reverting cointegration error. It first simulates the change in one asset’s price as an autoregressive process, cumulatively sums those changes into a price…

StatisticsPairs tradingMean reversionBacktesting
Stratmill research code

This reference explains two utilities for copula-based trading research: a linearly interpolated empirical cumulative distribution function (ECDF), and a quick selector for candidate pairs. A standard empirical CDF is a step function, which can map sparse…

Pairs tradingStatisticsBacktestingEquities
Stratmill research code

This module supports copula analysis by mapping observations to marginal empirical cumulative probabilities, with optional linear interpolation and probability bounds. It provides a multivariate row-wise transform, fits a supplied copula to two series after…

StatisticsPairs tradingDerivatives pricingRisk management
Stratmill research code

Hedge ratios set the relative sizes of legs in a spread so that price differences do not leave the position unintentionally unbalanced in dollar terms. The document introduces a simple price-ratio method, then describes normalizing weights so the dependent…

Pairs tradingMean reversionStatisticsPortfolio construction
Stratmill research code

This method adapts mean-reversion pairs trading to the risk that a spread shift reflects a lasting structural change rather than a temporary deviation. It models the pair spread as having two Markov-switching states, each with its own mean and volatility,…

Pairs tradingMean reversionArbitrageStatistics
Stratmill research code

This code describes a C-vine copula wrapper intended for statistical arbitrage research. It fits candidate vine structures to quantile-transformed data, restricts the candidate ordering according to a chosen target variable, and selects the structure with…

StatisticsArbitragePairs trading