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
Alphalens
14 documents
WonderTrader
14 documents
backtesting.py
11 documents
Technical Analysis
9 documents
QTPyLib
8 documents
Lumibot strategies
7 documents
QuantRocket
7 documents
Awesome Quant
1 documents

Search the library

765 documents

Quant Q&A

The document asks whether pairs trading can be applied to related options or to an option and its underlying asset. The proposed idea is to trade a stationary linear combination over short horizons, where changes in delta and time decay may have less…

OptionsPairs tradingStatisticsVolatility
Quant Q&A

The document asks whether a pairs trading strategy should retest cointegration each day using a rolling window, rather than test once during an initial formation period and then trade the selected pair for a fixed holding period. The proposed approach uses…

Pairs tradingStatisticsMean reversionBacktesting
Quant Q&A

The document asks how to interpret the Phillips–Ouliaris test in R’s urca package and whether its output contains an estimated cointegrating vector. It constructs a bivariate example with a known relation, runs the test, and reports a statistic above the…

StatisticsPairs trading
Quant Q&A

The document discusses how to choose the observation window and retesting frequency for cointegration methods such as the ADF and Johansen tests when designing a pairs strategy. It rejects a universal lookback standard and relates the choice to data…

Pairs tradingStatisticsBacktestingMean reversion
Quant Q&A

The note addresses a pairs trading setup that selects pairs using the sum of squared distances between normalized prices, then monitors the resulting spread. It raises concerns about unequal dollar values in the long and short positions and whether the…

Pairs tradingMean reversionRisk managementPosition sizing
Quant Q&A

The document asks how to profit if one asset earns a higher return than another over a fixed period, regardless of whether either asset rises or falls. The answers identify a pair trade as a direct way to express that view: go long the expected outperformer…

Pairs tradingEquitiesFuturesOptions
Quant Q&A

This note raises a modeling question about calculating a spread for mean-reversion pairs trading with a Kalman filter. It contrasts the measurement prediction error, formed from the observed value and the filter’s predicted measurement, with a residual…

Pairs tradingMean reversionStatisticsBacktesting
Quant Q&A

The document asks whether a long-short portfolio formed from a cointegrated pair can be shown to have zero CAPM beta. It writes the portfolio’s market exposure as the beta of the long position minus the hedge ratio times the beta of the short position.…

Pairs tradingPortfolio constructionRisk managementStatistics
Quant Q&A

The document considers how to rank pairs of securities modeled with a time-varying linear relationship. In a state-space regression, a Gaussian Kalman filter produces state covariance estimates and prediction errors. The example applies this setup to daily…

Pairs tradingEquitiesStatisticsRisk management
Quant Q&A

The document considers whether market makers can find opportunities in two share classes with equal cash flow rights but different voting rights and liquidity. Its answer suggests that the classes’ market values may move together over time, while liquidity…

EquitiesMarket makingPairs tradingRisk management
Quant Q&A

The document discusses how to compare two correlated futures contracts whose prices and tick sizes differ when building a pairs strategy. One suggested approach sets both starting prices to one, then compounds each instrument’s percentage price changes to…

FuturesPairs tradingStatisticsBacktesting
Quant Q&A

The document asks how to prepare E-mini S&P 500 and Nasdaq futures prices for a cointegration test when their contract multipliers differ. One proposed method multiplies each quoted price by its contract multiplier, producing notional values that can be…

FuturesStatisticsPairs trading
Quant Q&A

The document asks how to turn the output of a Johansen cointegration test into a spread for a two-stock pairs trading strategy. The trader contrasts the method with a spread formed from an ordinary least squares hedge ratio, where one stock is reduced by a…

Pairs tradingStatisticsEquitiesBacktesting
Quant Q&A

This note considers replacing a long stock and short stock position in a pairs trade with synthetic option positions. It asks whether the synthetic exposure has the same risk and reward as holding the underlying shares directly. The response suggests that…

Pairs tradingEquitiesOptionsExecution
Quant Q&A

The document explains how to estimate an Ornstein–Uhlenbeck process for mean-reverting data, motivated by simulating a stock-price spread for pairs trading. It discretizes the process over equally spaced observations and relates the resulting equation to an…

Mean reversionPairs tradingStatistics
Quant Q&A

The discussion asks how to choose the number of historical candles used to estimate a spread z-score in a crypto perpetual swap pairs strategy. The question notes that different pairs appear to perform best with different window lengths in both backtests and…

CryptoPairs tradingPerpetual futuresBacktesting
Quant Q&A

This exchange explains how to read Johansen test statistics against their critical values when testing whether two stock price series share a cointegrating relationship. The example shows separate null hypotheses for rank zero and rank at most one, and…

StatisticsPairs trading
Quant Q&A

This document is a broad reading list for research on cointegration, statistical arbitrage, and pairs trading. It points readers toward foundational work on cointegration testing and error correction, empirical studies of relative-value strategies, and books…

Pairs tradingArbitrageMean reversionStatistics
Quant Q&A

The document asks how to assess whether a cointegrated pair’s spread mean and variance remain stable over time, so entry and exit limits can be set systematically. It frames the spread as a regression residual and considers regime-switching models as a…

Pairs tradingMean reversionStatisticsRisk management
Quant Q&A

The discussion explains how to apply White’s Reality Check or a permutation test to a pairs strategy. It represents trading decisions as a position vector, such as long, short, or flat, and randomly permutes that vector to generate simulated strategy…

Pairs tradingStatisticsBacktesting
Quant Q&A

The document asks what dynamics for two assets can produce a spread that follows an Ornstein–Uhlenbeck process. The answer gives one sufficient construction: model both component assets as OU processes with the same mean-reversion speed and correlated…

StatisticsMean reversionPairs trading
Quant Q&A

The document sets up a spot portfolio containing two stocks whose prices are related by a proposed cointegration expression. It assigns coefficients to the two prices, defines a position indicator that can take long, flat, or short values, and writes the…

EquitiesPairs tradingPortfolio construction