# Tag Info

16

Pair trading is a market neutral bet. Instead of saying the market in general is going higher, you say one investment under/overvalued relative to another, typically similar, investment. The bet is that the spread between the two will widen or narrow depending on how you set it up. For instance, say I feel GM is going to outperform Ford over the next year....

11

There are multiple approaches that you could consider. The basic idea across all of them is that you want to find a portfolio that is stationary. In the two-asset case, it is well known how to accomplish this. This paper by Marcelo Perlin describes one approach: http://papers.ssrn.com/sol3/papers.cfm?abstract_id=952782 but I am not particularly inclined to ...

10

Quantitative pair trading (as we are on the quantitative finance forum) is based on cointegration. Two stocks are said to be cointegrated if they move together, which means that they share the same long term trend. Precisely: It exists a linear relationship between the price of the 2 stocks so that is mean reverting. (for instance the difference between ...

9

For years, I performed this brute-force search daily on my universe of tradable stocks and futures. It is a waste of time. If your computer discovers that hog futures and MSFT are cointegrated, for example, do you really care? I would never trade that pair. There is no economic connection between hogs and Microsoft, so I must assume that the reported, small ...

9

$\theta$ is the "mean" for this process. If $X_t > \theta \implies (\theta - X_t) < 0$, which means that the drift for the process is negative and tends towards $\theta$. The opposite case can be made for $X_t < \theta$ ; the process will have positive drift when $X_t$ is below $\theta$. Therefore we can consider $\kappa$ to be the "speed" of mean ...

8

Theoretically, the answer to the question is yes, a correlation matrix for potential pairs trades can be computed in $O\left((n^2t)^{(\omega+\epsilon)/3}\right)$ time, for any $\epsilon > 0$, where $\omega < 2.38$ is the so-called exponent of matrix multiplication. However, these algorithms have a reputation for having a very large constant factor ...

5

Sharpe should only be computed from daily returns because finer granularity leads to a larger sample size. The larger sample makes the standard deviation metric more accurate. As a counter-example, how reliable would the Sharpe be using yearly returns?

5

Pairs trading is just one type of statistical arbitrage (check out references on wikipedia page). It sounds like you are talking about trading "factors" against each other. Factors could be industries, size, fundamentals, or purely statistical. Start with Ed Thorp's Wilmott articles on statistical arbitrage. Then read Attilio Meucci's Review. An example ...

5

Such tests should always be done using adjusted prices. In fact, ideally, you should reconstruct your own price series using the total returns series. To see this, suppose you have a 10:1 split rather than a relatively small cash dividend. Then it is clear that the cointegration relationship can only hold with respect to the adjusted series.

5

Fatih Yilmaz, formerly of Bank of America (currently BlueGold), has a piece called "Imaginal Spreads and Pairs Trading" on exactly this topic, if you can find it (I couldn't find a copy on the public internet), originally published April 17, 2009. He writes: Academics and industry practitioners generally concentrate on time series aspects of currency ...

5

Well, "mean reversion trading" could mean a lot of things, I am not qualified to describe it in full generality. However, there is a simple model of mean reversion called the Ornstein Uhlenbeck process that is often seen. It has two parameters \lambda and \sigma, where lambda is the strength of the mean reversion (so one over lambda is the mean reversion ...

4

if you just want to test for significance of the generation of returns exceeding a hurdle rate then you can just setup a standard hypothesis test where you test whether your returns you generate from back tests exceeds a certain return. if you are more interested in testing for co-integration then you should consider the Johansen and/or Engle-Granger tests ...

4

It depends on which return you precisely attempt to measure: Gross Return on trade: Forget about margin or not margin, it does not matter. When you evaluate the performance of a single position you look at the notional to which you exposed yourself to. So if you bought a stock worth 100 dollars and later on sell it for 110 dollars then you generated a ...

4

The basic idea of pair trading is to find two symbols (I'll use that to mean stocks, futures, anything you can trade) that historically have correlated price movements. Then if just one of them increases in price you short that symbol, and buy its pair, on the assumption that they will soon go back in sync. However when you think there is a genuine reason ...

4

Disclaimer: I know nothing about FX trading, other than that I've heard something to the effect of "The first rule of FX trading is that you do not trade FX. The second rule..." you know how it goes. I'm not into macroeconomics, but I get the impression that the benchmark for FX models is a random walk. That is to say that the fundamentals have nothing to ...

4

Have you checked out the vingette for DLM by Petris? Incidentally, Petris also has an R-book on the DLM package which includes estimation of beta as an example.

4

The following link has a good summary of a typical pair trading strategy: https://www.quantstart.com/articles/Backtesting-An-Intraday-Mean-Reversion-Pairs-Strategy-Between-SPY-And-IWM It actually has full python code as well. It doesn't include a cointegration check though. Edit: if X and Y are cointegrated: calculate Beta between X and Y ...

3

It really depends on the source of your signal. Since you're trading options I assume it is either volatility signal, or volatility + basis signal. If you have signal only on basis don't bother with options and just trade underlying. Now if you are trading vol signal only, you will need to hedge all basis risk - so gamma hedge (dynamic hedging with ...

3

How about an O(N log(n)) solution ? To be a viable trading strategy, you often expect them variances to be similar, so just calculate ordinary volatility and put it in an ordered array. Of course that's going to be period dependent, so pick a few arbitrary periods and see which instruments end up being together. Then you get clusters of vastly smaller ...

3

Of course you get through diversification effects different return variation and thus Sharpe ratios depending on whether you calculate the standard deviation on an individual asset or a portfolio standard deviation on a collection of assets. A pairs trade is a small portfolio so with favorable correlation properties you should generally get a better risk ...

3

Here is a link to a paper with concrete details of calculating the hedge ratio for your position: http://quanttrader.info/public/betterHedgeRatios.pdf. Certainly, you want to check that it is reasonable to hedge one position with the other, as Freddy warns. But assuming it is, the paper suggests that using total least squares is better than using ordinary ...

3

I urge you to not compare CDS contracts and pairs with cash equity pair trades. The profiles are entirely different. CDS pairs are much more similar to being long and short an options contract. As protection buyer you are essentially long an option, you pay an "insurance premium" and that is what you are standing to lose at maximum. However, as protection ...

3

Your spread does not look similar to the random walk. Many of the observations are the same as the previous observation. This means most of the first differences are zero, which is why the test indicates your series has a unit-root. The current value is very good at explaining what the next value will be.

3

O-U is continuous time mean reverting process, hence used to model stationary series. It has closed form analytic solution. This allows insight into stationary processes and act like asymptotic limiting case for calculating coefficients that matter. EDIT: You can see AR(1) below $$x_{k+1} = c + a x_k + b\varepsilon_k$$ and by substituting c=θμΔt, a=−θΔt ...

3

Being very fast within a single datacenter is not as valuable as having the fastest line between two datacenters. So being able to write a very fast program wouldn't be the holy grail of trading anyway (it would be to instantaneously transport information between e.g. NJ and Chicago using quantum entanglement or something.) That said, if you found an ...

3

It depends on if you are trying to do a Dollar neutral hedge or a beta neutral hedge. Method 1 is a Dollar neutral hedge and Method 2 is the Beta neutral hedge ratio. Remember that even if you find a cointegrated pair, share A can have a higher beta than share B.

2

I would concur with Chrisaycock if the volatility between two assets is constant, but because it never is I find there are way better approaches. Generally correlations fly all over the map once things start to become interesting in the market, even for generally highly correlating assets. I would look to generate an algorithm that can determine a range of ...

2

I think that it is better to look at t-stat than at the Sharpe Ration itself with data using different frequencies (thus different df) in order to determine which Sharpe Ratio stat is more accurate. Calculation can be found in this paper: The Statistics of Sharpe Ratios.

2

I personally would not do that! Your regression model has been fitted to approximate $Y(t)$ (the reality) as much as possible. If I understand you well, you say: at the previous period $Y(t)=55$ (Starbucks traded at 55 USD) the last period's estimate from the regression is $\hat{Y}(t)=60$ Since $\hat{Y}(t)-Y(t) > 0$, you want to invest. This does ...

2

Please see e.g. wikipedia entry for cointegration. You should also probably read the original paper here and/or the book by Vidyamurtha. Vidyamurtha's book is a bit messy, but IMO quite OK. Also, I think it's going to be pretty hard to make pairs trading work in practice. It's just a too old idea and it's being done too much and you're going to have a ...

Only top voted, non community-wiki answers of a minimum length are eligible