Nunzio Tartaglia / Morgan Stanley; documented by Ernest Chan
Pairs trading: why correlation is not enough, and cointegration is
Almost every description of pairs trading says to find two correlated stocks. That is the wrong property, and the error is not academic: two assets can be 95% correlated and still drift apart forever. The property that makes the trade work is cointegration — a statistical guarantee that the gap between them is bounded — and it has to be tested for, because it is invisible on a chart.

- Style
- Mean reversion
- Approach
- Mechanical
- Difficulty
- Advanced
- Horizon
- Swing (days to weeks)
- Holding period
- Days to weeks
- Time needed
- 30 minutes a day plus periodic model review
- Markets
- Stock pairs · ETF pairs · Futures spreads
- Source
- Originating with Nunzio Tartaglia's group at Morgan Stanley in the 1980s; the modern retail treatment follows Ernest Chan's Algorithmic Trading — Nunzio Tartaglia / Morgan Stanley; documented by Ernest Chan
The rule set
- Use a cointegration test — Engle-Granger or Johansen — to find pairs whose spread is statistically stationary, not merely correlated
- Estimate the hedge ratio by regressing one price series on the other; that ratio determines the relative size of the two legs
- Compute a rolling z-score of the spread against its own recent mean and standard deviation
- Open when the z-score passes the entry threshold — long the cheap leg, short the rich one — and close as it returns toward zero
- Set a stop on the spread itself: a z-score that keeps widening past a threshold means the relationship has probably broken
- Re-test cointegration on a schedule; a pair that qualified last year may not qualify now
What makes it distinctive
- Market neutral by construction: a broad market move affects both legs and largely cancels, so the bet is on the relationship alone
- Entries and exits come from the statistical distribution of the spread rather than from any judgement about either instrument
- It requires the ability to short at a reasonable borrow cost, which is a real constraint rather than a technicality
When it works
Between instruments driven by the same underlying economics — two companies in the same industry with the same inputs and customers, or two ETFs tracking related exposures — under normal liquidity conditions.
When it fails
When the relationship breaks permanently. A merger, an accounting scandal, or a genuine divergence in the two businesses turns a temporary spread into a widening one, and the position loses on both legs simultaneously. Borrow costs, share recalls and slippage all subtract from an already thin edge.
How a decision moves through it
Input
Two aligned price series, plus borrow availability
Prices must be adjusted consistently for dividends and splits on both legs. An unadjusted series introduces artificial jumps into the spread that look exactly like trading signals.
Measure
Cointegration test and hedge ratio
The statistical foundation. This is the step that separates a real pairs trade from two vaguely related stocks, and it produces the ratio the position sizes depend on.
Measure
Rolling z-score of the spread
How many standard deviations the current spread sits from its own recent mean. The lookback window is the system's main parameter and the one most easily overfitted.
Decide
Has the z-score passed the entry threshold?
Symmetric: a positive extreme means short the first leg and long the second, a negative one the reverse.
Act
Open both legs at the hedge ratio, close near zero
Both legs must be executed together. Legging in — one now, one later — reintroduces exactly the directional risk the structure was built to remove.
The distinction the whole system rests on
Correlation measures whether two series move in the same direction at the same time. Cointegration measures something quite different: whether the gap between them is bounded — whether, having drifted apart, they are pulled back together.
Two stocks can be highly correlated and drift apart indefinitely. Imagine one growing 15% a year and the other 5%: their daily moves rise and fall together, correlation is high, and the spread widens forever.
| Correlation | Cointegration | |
|---|---|---|
| Measures | Do they move together day to day? | Is the gap between them bounded? |
| Can be high while the pair diverges | Yes | No — that is the definition |
| Visible on a chart | Roughly | No — it must be tested |
| What a pairs trade needs | Not sufficient | This one |
This is not a technicality. A pairs strategy built on correlation has no mechanism to bring the spread back, which means the exit — 'close when it converges' — rests on nothing. The trade may be waiting for a convergence that was never statistically implied.
What market neutrality does and does not remove
Holding a long and a short of similar size means that when the whole market falls 5%, both legs move together and the position is roughly unaffected. The systematic risk that dominates every other strategy in this library has been hedged away.
- Removed: market direction, and most sector-wide moves if the pair is within a sector.
- Not removed: anything specific to one of the two companies. An earnings miss on one leg is exactly the event the structure has no defence against.
- Introduced: borrow cost, recall risk, twice the transaction costs, and the risk that the statistical relationship was never real.
This one was genuinely arbitraged
Pairs trading was extraordinarily profitable for Morgan Stanley's group in the 1980s, when identifying the relationships required proprietary computing power that few had. Published academic work through the 1990s and 2000s documented the strategy's returns declining steadily as it became widely known and implemented.
This is the clearest case in the library of an edge being competed away. It is not a claim that the strategy cannot work — it is a claim that the obvious version of it, on liquid large caps, is being run by people with better data and lower costs than you.
Five ways into this system
- Testing for cointegration, estimating the hedge ratio, and trading the spreadFour steps, each with a statistical decision in it, and one of them is where most implementations go wrong.8 min read
- Sizing two legs, and the costs that decide whether the edge survivesTwo positions, two sets of costs, and a stop expressed in standard deviations rather than in price. Each of those changes how sizing works.6 min read
- What you need before this is even possible: borrow, data and a reasonThis is the highest-barrier system in the library. Three of its requirements are infrastructure rather than skill.5 min read
- The break: when the spread widens and never comes backThree failure modes: the relationship ends, the relationship was never there, and everyone else holds the same position you do.7 min read
- Pairs trading for beginners: betting on a gap instead of a directionThe idea is elegant and the execution is the most demanding in this library. This page covers the concepts and is honest about the barriers.6 min read
The ideas behind it
This system assumes you already know these. Each one is explained from scratch in Investing 101.
Compare with
- RSI(2) Mean Reversion (Connors)Inside a long-term uptrend, buy the sharpest short-term pullbacks and sell into the bounce a few days later.
- All Weather PortfolioHold a fixed mix of shares, long and intermediate bonds, gold and commodities chosen so that something in it works in every economic environment.
These are documented methods described for study. Nothing here is investment advice, a recommendation, or a claim about future returns — every system on this page has losing periods, and the pages say where.
Reading about a system is not having one.
Plutux is where you write your own rules down, test them against real data, and keep the record your memory would otherwise rewrite. Join the waitlist for early access.