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

Quant Q&A

When a trading platform prohibits shorting individual stocks but allows short positions in index futures, a desired long-short stock portfolio may be approximated using an index that contains the relevant names. The example targets a long position in one…

EquitiesFuturesPairs tradingArbitrage
Quant Q&A

The document asks how to calculate returns for a spread that is long aluminium and short a weighted amount of lead. It compares a change in spread value divided by a contemporaneous sum of leg values with a weighted combination of the two commodities’ price…

CommoditiesStatisticsPairs trading
Quant Q&A

The document asks whether the Kolmogorov–Smirnov test can establish that a time series is normally distributed and whether normality can then establish market efficiency. The responses describe the K–S test as a way to compare a sample with a reference…

StatisticsMarket microstructurePairs trading
Quant Q&A

The document asks whether optimal entry and exit thresholds for an Ornstein–Uhlenbeck mean-reversion strategy should move one-for-one when the process mean changes. It frames the question through the thresholds relative to the mean and the symmetry between…

Pairs tradingMean reversionStatistics
Quant Q&A

The discussion considers how to choose the observation window for cointegration tests on financial time series. It offers no formal universal rule: a relationship may appear in one sample length and disappear in another, so comparing results across windows…

StatisticsPairs tradingEquities
Quant Q&A

The document addresses why ordinary percentage returns can become misleading when a long-short strategy’s recorded P&L or value crosses zero. It presents a net asset value approach: account for the value of long holdings, short-sale proceeds, and the current…

EquitiesPairs tradingBacktestingPortfolio construction
Quant Q&A

The document collects suggested starting points for learning cointegration before moving on to a more advanced market models text. Respondents point to a general reference, an accessible paper, and a short introductory book. The book is described as…

StatisticsPairs trading
Quant Q&A

The discussion considers how to choose a lookback period, entry and exit thresholds, and candidate pairs without mistaking data mining for evidence of a durable edge. It frames mean reversion as an assumption to test, then recommends defining model…

Pairs tradingMean reversionBacktestingStatistics
Quant Q&A

The document discusses how to evaluate a historical ratio between corn and soybean futures and how to express a trade in the relationship. One answer frames this as pairs trading or statistical arbitrage, recommending a cointegration check, such as an…

FuturesCommoditiesPairs tradingMean reversion
Quant Q&A

The document compares two spread definitions used to trigger Z-score entries in automated pairs strategies: residuals from an ordinary least squares regression of log returns, and the log ratio of the two contract prices. The author reports that the…

Pairs tradingFuturesCryptoMean reversion
Quant Q&A

The document raises two practical questions about turning cointegration relationships into a pairs trading portfolio. It compares a regression of log prices with one using raw prices, each expressed as a fitted relationship between assets and a residual…

Pairs tradingStatisticsPortfolio constructionPosition sizing
Quant Q&A

The document asks whether a negative coefficient in a cointegrating relation changes how a stock pair should be traded. Its example uses two beverage stocks and a spread formed by regressing one price on the other. It compares the sign of the coefficient…

EquitiesPairs tradingMean reversionStatistics
Quant Q&A

The document explores holding a stock-pair spread when it appears to follow a rising linear trend, rather than requiring the spread to be stationary as in conventional mean-reversion pairs trading. The author estimates hedge ratios by ordinary least squares…

Pairs tradingEquitiesStatisticsRisk management
Quant Q&A

The question describes a live arbitrage setup that compares prices for many product pairs using separate trading and market data APIs. It seeks a way to monitor the pairs continuously without unnecessary looping, distinguishing live system design from…

ArbitragePairs tradingExecution
Quant Q&A

The document distinguishes a relative-value volatility position from a true arbitrage when options reference different assets. A trader might buy the lower implied-volatility option and sell the higher one, sizing the legs to manage delta and possibly vega…

OptionsVolatilityArbitrageRisk management
Quant Q&A

The document considers whether to size the long and short legs of a pairs trade in proportion to each stock’s price variance. The proposed intuition is to allocate more capital to the more volatile asset, which may move more as the spread converges. The…

Pairs tradingVolatilityPosition sizingRisk management
Quant Q&A

The document raises a methodological concern in pairs trading: a trader forms pair spreads using hedge ratios estimated by rolling linear regressions, then applies the Augmented Dickey–Fuller test to those spreads. In the described experiment across a set of…

Pairs tradingStatisticsBacktesting
Quant Q&A

The document raises a question about soybean and soybean meal futures, which the author describes as highly correlated because they share an underlying agricultural market. A linear regression between the two series produces residuals that fail an Augmented…

FuturesCommoditiesStatisticsPairs trading
Quant Q&A

The document addresses how to monitor a previously estimated cointegrating relationship between two time series when repeatedly rerunning a cointegration test is too expensive. Given an existing regression of one series on the other, it proposes calculating…

Pairs tradingStatisticsRisk management
Quant Q&A

The document discusses whether options can reproduce an index that tracks one asset’s performance relative to another, such as a stock against a broad market benchmark. It distinguishes the index exposure from an option on that index: a long position in the…

EquitiesOptionsPairs tradingFutures
Quant Q&A

The document explains the mechanics of a stock pairs trade: borrow and sell one stock, use the proceeds to buy another, then close both legs when their relative performance meets the strategy’s exit condition. It clarifies that the spread need not return to…

Pairs tradingEquitiesExecutionRisk management
Quant Q&A

The note asks how Johansen cointegration analysis differs from fitting a vector autoregression to multiple integrated stock price series. The proposed cointegration approach tests whether a weighted combination of nonstationary series is stationary, then…

EquitiesStatisticsPairs trading