Introduction to Distance Approach in Pairs Trading: Part II

by Joohwan Ko

Distance Approach in Pairs Trading Part II Cover

Join the Reading Group and Community: Stay up to date with the latest developments in Financial Machine Learning!

Introduction

We have discussed Basic Distance Approach in the previous blog post. In this post, we’ll look into one of the advanced methods in the Distance Approach and its differences to the Basic Distance Approach. If you haven’t read the previous blog post, we recommend reading it before you read this post:

Pearson Correlation Approach

So, what is the Pearson Correlation Approach? It is a type of Distance Approach and applies Pearson correlation on return level for identifying pairs. The main concept is similar to the Basic Distance Approach, where pairs are formed with a particular rule, and a portfolio is constructed based on the trading signals of pairs.

D_{i j t}=\beta\left(R_{i t}-R_{f}\right)-\left(R_{j t}-R_{f}\right)

The equation above shows the key concept of the Pearson Correlation Approach, where D is return divergence and \beta is the regression coefficient of stock_i‘s monthly return on its comover return R_{j t}. A portfolio is constructed after sorting stocks in descending order based on their previous month’s return divergence.

Portfolio Formation

The main concept of this method is to form pairs using Pearson Correlation. Then how do we form portfolios with these pairs? There are three steps in the Portfolio Formation part.

  1. Data Preprocessing
  2. Pairs Portfolio Formation
  3. Trading Signal Generation

Data Preprocessing

First, we need to split the input data. When the prices of stocks are given as an input, the method split data as follows: price data from year t-4 to year t for pairs portfolio formation and price data in year t+1 for trading. Besides data split, this method usually manipulates the data for further use. As the method has to compute all of the pairs’ correlation values in the following steps, for m stocks, there are \frac{m*(m-1)}{2} correlations to be computed in the formation period. As the number of observations for the correlations grows exponentially with the number of stocks, this estimation is computationally intensive.Therefore, this method uses monthly stock returns data in the formation period (ex. 60 monthly stock returns if the formation period is 5 years). Although this manipulation is not necessary, this step may reduce some unnecessary noises of the input data.

Pairs Portfolio Formation

In the pairs portfolio formation, we have to find pairs first. For each stock, find n stocks with the highest correlations to the stock. After the pairs are selected for each of the stocks, the pairs portfolio formation needs to be done. This “Portfolio” is not the portfolio we will trade in the end but a benchmark portfolio for each of the stocks. That being said, the portfolio of those n stocks only serves as a benchmark for portfolio sorting in the following steps. So, we are setting the pairs portfolio’s returns as the equal-weighted average returns of the top n pairs of stocks. Below is an example of a pair with a high Perason correlation coefficient.

Two price series of stocks with a high Pearson Correlation

Fig. 1. Plot of two price series of stocks with a high Pearson Correlation.

After pairs portfolios are formed, the method derives \beta from the monthly return of the stock and its pairs portfolio as follows:

R_{j t}=\alpha+\beta\left(R_{i t}\right)

By using linear regression, setting stock return as independent variable and pairs portfolio return as the dependent variable, the methods set \beta as a regression coefficient.

Fig. 2. The first plot shows a stock with a high \beta and the second plot shows a stock with a low \beta.

Trading Signal Generation

The pairwise trading hypothesis is that if a stock’s return deviates from its pairs portfolio returns in any given month in year t + 1, this divergence will be reversed in the following month. The return divergences are calculated with the beta created in the formation period as follows:

D_{i j t}=\beta\left(R_{i t}-R_{f}\right)-\left(R_{j t}-R_{f}\right)

Then, all stocks are sorted in descending order based on their previous month’s return divergence. If the percentages of long/short stocks are given (say 𝑝% and 𝑞%) , the top 𝑝% of the sorted stocks are chosen for the long stocks, and the bottom 𝑞% of the sorted stocks are chosen for the short stocks. A dollar-neutral portfolio can be constructed by longing decile 10 and shorting decile 1, and held for one month.

Differfence to Basic Distance Approach

There are two main differences between the Pearson Approach and Basic Approach.

  1. Less strict than SSD minimization
  2. Higher information level contained in a diversified comover portfolio

Less strict than SSD minimization

According to Krauss(2017), let’s take a look at the equation of variance of price spread. In the case of the Basic Distance Approach, we assume that minimizing SSD leads to a minimization of price spread variance. The variance of the spread price reaches its minimum of zero if the two stock prices are perfectly correlated and their price time series exhibit the same variance. Therefore, the minimum SSD criterion thus finds asset prices with similar variance and high correlation.

 \mathrm{V}\left(P_{i t}-P_{j t}\right)=\mathrm{V}\left(P_{i t}\right)+\mathrm{V}\left(P_{j t}\right)-2 r\left(P_{i t}, P_{j t}\right) \sqrt{\mathrm{V}\left(P_{i t}\right)} \sqrt{\mathrm{V}\left(P_{i t}\right)}

On the other hand, if we look at the equation of variance of return spread, constraining for high return correlation leads to lower variance of spread returns. However, the returns of the individual assets may still exhibit different variances.

 \mathrm{V}\left(P_{i t}-P_{j t}\right)=\mathrm{V}\left(P_{i t}\right)+\mathrm{V}\left(P_{j t}\right)-2 r\left(P_{i t}, P_{j t}\right) \sqrt{\mathrm{V}\left(P_{i t}\right)} \sqrt{\mathrm{V}\left(P_{i t}\right)}

Higher information level contained in a diversified comover portfolio

Return divergences from such a portfolio are more likely to be caused by idiosyncratic movements of stock_i, and thus potentially reversible. This hypothesis was tested by Perlin(2007, 2009) that there are advantages of quasi-multivariate pairs trading versus univariate pairs trading. Quasi-multivariate pairs trading results in higher and more robust annual excess returns than univariate pairs trading for a broad range of different threshold values.

Possible Improvements

There are still some limitations of this approach and can be improved in various ways. Below are some examples of them:

  • Two assets correlated on return level do not necessarily share an equilibrium relationship.
  • As there is no theoretical foundation that divergences need to be reversed divergence reversion needs to be further tested.
  • One may add a cointegration test to the selected pairs.

Check out our lecture on the topic: