step by step guide: pair trading and statistical arbitrage

26
Statistical Arbitrage: Pair Trading Shaurya Chandra Quantinsti

Upload: quantinsti

Post on 22-Jul-2015

198 views

Category:

Economy & Finance


7 download

TRANSCRIPT

Page 1: Step by Step Guide: Pair Trading and Statistical Arbitrage

Statistical Arbitrage: Pair TradingShaurya ChandraQuantinsti

Page 2: Step by Step Guide: Pair Trading and Statistical Arbitrage

Content Index

• Process of Quant- Trading Strategy

• Statistical Arbitrage

• Pair Trading Strategy

• Implementation Methodology

• Example of Prices of two Cement Stock

• Pair Ratio Behavior

• Why Pair Trading Work?

• Key Decision Points for Pair Trading & Risk Area

• Investor Decisions

• Stationary Process

Page 3: Step by Step Guide: Pair Trading and Statistical Arbitrage

Content Index

• What’s Co-integration?

• Correlation Vs. Co-integration

• Correlation Calculation

• Co-Integration

• Co-Integration- Mathematical Definition:

• Co-integration calculation

• Pair Ratio Movement for Above Example

• Z-score

• Process of Pair Selection

• Other key points to be kept in mind

Page 4: Step by Step Guide: Pair Trading and Statistical Arbitrage

Process of Quant- Trading Strategy

Hypothesis Formulation

Back-Testing & Hypothesis Verification

Parameter Optimization

Going Live with Strategy

Page 5: Step by Step Guide: Pair Trading and Statistical Arbitrage

Statistical Arbitrage

Restricted AccessPlease contact us at [email protected]

Page 6: Step by Step Guide: Pair Trading and Statistical Arbitrage

Pair Trading Strategy

Restricted AccessPlease contact us at [email protected]

Page 7: Step by Step Guide: Pair Trading and Statistical Arbitrage

Implementation Methodology

Select pair

of stocks that

move together

closely

1

Wait until

prices diverge

beyond a certain

threshold, then

short “winner”

and buy

“loser”

2

Reverse your

positions when

the two prices

converge --> Profit

from the reversal

in trend

3

Page 8: Step by Step Guide: Pair Trading and Statistical Arbitrage

0.00

20.00

40.00

60.00

80.00

100.00

120.00

140.00

160.00

180.00

0

200

400

600

800

1000

1200

1400

3-Jan-05 3-Jan-06 3-Jan-07 3-Jan-08 3-Jan-09 3-Jan-10

ACC Ambuja

Example of Prices of two Cement Stock

Page 9: Step by Step Guide: Pair Trading and Statistical Arbitrage

0.100

0.105

0.110

0.115

0.120

0.125

0.130

Price Ratio 30 Day MA

Pair Ratio Behavior

Page 10: Step by Step Guide: Pair Trading and Statistical Arbitrage

Why Pair Trading Work?

Restricted AccessPlease contact us at [email protected]

Page 11: Step by Step Guide: Pair Trading and Statistical Arbitrage

Key Decision Points for Pair Trading & Risk Area

Restricted AccessPlease contact us at [email protected]

Page 12: Step by Step Guide: Pair Trading and Statistical Arbitrage

Investor Decisions

Restricted AccessPlease contact us at [email protected]

Page 13: Step by Step Guide: Pair Trading and Statistical Arbitrage

Stationary Process

Restricted AccessPlease contact us at [email protected]

Page 14: Step by Step Guide: Pair Trading and Statistical Arbitrage

What’s Co-integration??

Restricted AccessPlease contact us at [email protected]

Page 15: Step by Step Guide: Pair Trading and Statistical Arbitrage

Correlation vs Co-integration

Restricted AccessPlease contact us at [email protected]

Page 16: Step by Step Guide: Pair Trading and Statistical Arbitrage

Correlation Calculation

Restricted AccessPlease contact us at [email protected]

Page 17: Step by Step Guide: Pair Trading and Statistical Arbitrage

Co-Integration

Restricted AccessPlease contact us at [email protected]

Page 18: Step by Step Guide: Pair Trading and Statistical Arbitrage

Co-Integration- Mathematical Definition:

Restricted AccessPlease contact us at [email protected]

Page 19: Step by Step Guide: Pair Trading and Statistical Arbitrage

Co-Integration contd..

Restricted AccessPlease contact us at [email protected]

Page 20: Step by Step Guide: Pair Trading and Statistical Arbitrage

Co-integration calculation

Restricted AccessPlease contact us at [email protected]

Page 21: Step by Step Guide: Pair Trading and Statistical Arbitrage

0.7

0.75

0.8

0.85

0.9

0.95

1

1.05

Ratio Mean

Upper Line Lower line

Pair Ratio Movement for Above Example

Period:23-Oct-08 to 06-Nov-2009

30-Day Moving Average

+/- 2.25 Deviation

Mean fairly Stable

Page 22: Step by Step Guide: Pair Trading and Statistical Arbitrage

-2.5

-2

-1.5

-1

-0.5

0

0.5

1

1.5

2

2.5

3

Z-Score

Z-…

Z-score

Zscore = (Pair Ratio –mean)/ (Standard Deviation)

Page 23: Step by Step Guide: Pair Trading and Statistical Arbitrage

Process of Pair Selection• The Process:

• Create a list of pairs based on the same sector and similar market capitalization

• Decide on the time horizon of trade ( hours, days, week or months etc)

• Find pair correlation for the universe defined above, choose pair with correlation above 0.60 for the desired trading horizon

• Check whether pair is co-integrated

• Calculate Price Ratio, Moving Average of Price Ratio

• To Normalize, calculate, standard deviation for Price Ratio and subsequently, calculate Z-score

• Based on the Z-score, define the pair entry points. Generally, z-score above +2 and below -2 are considered to be good measure of probability of pair exhibiting mean reversion

• Execute pair on rupee-neutral basis.

• Define, Strict Stop-Loss and Profit mechanism before entering trade

• Its good practice to allocate fund to different pair portfolio rather than one signal trade

Page 24: Step by Step Guide: Pair Trading and Statistical Arbitrage

Other key points to be kept in mind

Restricted AccessPlease contact us at [email protected]

Page 25: Step by Step Guide: Pair Trading and Statistical Arbitrage

Bibliography

Restricted AccessPlease contact us at [email protected]

Page 26: Step by Step Guide: Pair Trading and Statistical Arbitrage

Thank You!

To Learn Automated Trading

Email: [email protected]

Connect With Us:

SINGAPORE

11 Collyer Quay,

#10-10, The Arcade,

Singapore - 049317

Phone: +65-6221-3654

INDIA

A-309, Boomerang,

Chandivali Farm Road, Powai,

Mumbai - 400 072

Phone: +91-022-61691400