Why Engle–Granger Cointegration Tests Depend on Regression Direction
Summary
The document compares two regressions of Whiting Petroleum and Approach Resources prices over the same period. It estimates a spread as one price minus an OLS hedge ratio times the other, then applies an Augmented Dickey–Fuller test. In one direction the spread passes the reported 5% stationarity threshold; after swapping the dependent and explanatory series, it does not. The example illustrates that this two-step cointegration procedure is asymmetric: reversing the regression changes the estimated residual series and can change the test result.
The post raises practical questions about choosing the regression direction and translating the estimated coefficient into long and short quantities. It does not resolve those questions or provide a robust trading rule. A single sample and test do not establish a durable relationship or profitability; the document also does not discuss alternative cointegration tests, structural stability, or trading costs. Its main value is identifying a modeling choice that should be handled explicitly when testing pairs strategies.
Key ideas
- OLS residual stationarity can differ when the dependent and explanatory assets are swapped.
- The estimated hedge ratio depends on which asset is treated as the response.
- An ADF result for one regression direction does not automatically validate the reversed spread.
- The example raises hedge-ratio sizing questions but does not establish a complete trading method.
Tags
Full text
# Cointegration stationary test yields different results if the pairs are swapped # Cointegration stationary test yields different results if the pairs are swapped I've been backtesting on a spread mean reversion strategy on certain stock pairs. I observe the stationarity via scatterplot and plotting a histogram. Then I verify it using Augmented Dickey Fuller test. Example: Whiting Petroleum Corporation (WLL) vs Approach Resources, Inc. (AREXQ) Time period: 01 Jan 2012 - 01 Jan 2013 Source: Yahoo Finance ``` Spread = Y-βX ``` β is obtained from performing OLS LinearRegression().fit using scikit in Python If I choose Y = AREXQ and X = WLL, I get β = 0.13470899 And the ADF results: ``` Results of Dickey-Fuller Test: Test Statistic -3.069995 p-value 0.028855 #Lags Used 0.000000 Number of Observations Used 89.000000 Critical Value (1%) -3.506057 Critical Value (5%) -2.894607 Critical Value (10%) -2.584410 This Time Series is STATIONARY ``` If I swap the tickers, Y = WLL and X = AREXQ, I get β = 5.85042859 And the ADF results: ``` Results of Dickey-Fuller Test: Test Statistic -2.739417 p-value 0.067462 #Lags Used 0.000000 Number of Observations Used 89.000000 Critical Value (1%) -3.506057 Critical Value (5%) -2.894607 Critical Value (10%) -2.584410 This Time Series is NON-STATIONARY ``` One is stationary and the other is not. Am I doing or understanding something wrong? Is there a criteria that I should only choose a certain pair to be Y or X? Or if there's one result that returns stationary, then i should assume it's stationary and apply the beta (hedge ratio) to long/short the pair instead? Example if hedge ratio = 0.13470899, I should LONG 0.135 WL and short 1 AREXQ whenever it hits the lower Zscore boundary. Thank you
Shown in full with attribution under the source's licence. Licence: CC BY-SA 4.0 (Stack Exchange)
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.