Skip to content

Pairs Trading

Difficulty intermediate

Concept

Pairs trading is a market-neutral strategy that exploits temporary price divergences between two historically correlated assets.

price                                                                   
  │                            ─── stock A (e.g. KO)                    
  │                            ─── stock B (e.g. PEP)                   
  │                                                                     
  │         ╱╲      A          ╱╲                                       
  │       ╱    ╲  ╱            ╱ ╲                                      
  │     ╱        ╳            ╱   ╲                                     
  │   ╱        ╱   ╲╲       ╱       ╲                                   
  │ ╱       ╱      ╲╲╲    ╱            B                                
  │       ╱          ╲╲╲╱                                               
  │     ╱              B                                                
  └──────────────────────────────────────────────────────→ time         

spread (A − β·B)                                                        
  │ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ●─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─  +2σ    
  │                       ╱   ╲ ←── short A, long B                     
  │                     ╱       ╲                                       
  │ ─ ─ ─ ─ ─ ─ ─●─ ─ ╱─ ─ ─ ─ ─ ●─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─  mean    
  │            ╱   ╲ ╱                ╲                                 
  │          ╱                          ╲                               
  │ ─ ─ ─ ●─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─●─ ─ ─ ─ ─ ─ ─ ─ ─  −2σ      
  │     long A, short B  →                                              
  └──────────────────────────────────────────────────────→ time         

  works when A and B are cointegrated (not just correlated)             
  test with engle-granger, johansen · re-test cointegration regularly  

Parameter Selection

Parameter Typical Value Notes
Lookback 60-120 days Longer = more stable, slower response
Entry Z-Score 1.5-2.5 Higher = fewer trades, higher quality
Exit Z-Score 0.0-0.5 Lower = capture more reversion
Stop Loss ±3.0-4.0 Protect against regime change

Risk Management

Monitoring

  • Cointegration breakdown — Re-test periodically
  • Hedge ratio drift — Recalculate rolling hedge ratio
  • Volume changes — Ensure liquidity in both legs
  • Corporate actions — Mergers, spinoffs, dividends affect relationship

Common Pair Types

Type Example Rationale
Same sector KO vs PEP Similar business models
Competitors XOM vs CVX Industry dynamics
ETF vs Component SPY vs largest holdings Arbitrage
Cross-asset Gold vs Gold miners Commodity linkage
Merger arb Acquirer vs Target Deal spread

Performance Expectations

Metric Typical Range
Win Rate 60-75%
Profit Factor 1.3-2.0
Sharpe Ratio 1.0-2.0
Max Drawdown 5-15%
Market Beta Near zero

Practical Guidelines

  1. Test Cointegration — Correlation ≠ cointegration
  2. Monitor Relationship — Pairs can break down
  3. Transaction Costs — Two legs = double costs
  4. Short Constraints — Ensure both legs can be shorted
  5. Diversify Pairs — Don't concentrate on one pair
  6. Have Stop Loss — Regime changes happen
  7. Check Fundamentals — Make sure the relationship makes sense

Next Steps