Technical Analysis and Statistical Arbitrage employ different tools and speak different languages. But they are trying to solve the same problem: create a good trading strategy. Is it possible to combine them?
2. 2
Fascinating Problem
Most people fall into one of two groups.
– Smaller group: Don’t know the difference
between technical analysis and statistical
arbitrage.
– Larger group: Don’t care about the
difference between technical analysis and
statistical arbitrage.
To me, unifying Technical Analysis and
Statistical Arbitrage is one of the most
fascinating problems in Finance Theory.
3. 3
My qualifications with regard
to this subject
I’ve been developing quantitative trading strategies for
more than 30 years
Ph.D. from MIT in mathematics/statistics
Professor of mathematics at Northeastern University
and adjunct professor of finance at NYU
Developing trading strategies in several Wall street
companies such as Susquehanna
With Philip Maymin created and ran Equity Derivative
and Statistical Arbitrage desk at Ellington
With Philip Maymin founded and ran a hedge fund
4. 5
Key Questions
What is Statistical Arbitrage?
What is Technical Analysis?
What do they have in common?
How do they differ?
What are their strengths and
weaknesses?
Can they be combined?
What does it mean to be honest in
developing trading strategies?
5. 6
Statistical Arbitrage Language
SA Speak:
The magnitudes and
decay pattern of the
first twelve
autocorrelations
and the statistical
significance of the
Box-Pierce Q-statistic
suggest the presence
of a high-frequency
predictable component
in stock returns.
Campbell, Lo, MacKinlay 1997
Trades Discovery Language – Probabilistic Model
Performance Language
6. 7
Technical Analysis Language
TA Speak:
The presence of clearly identified
support and resistance levels,
coupled with a one-third
retracement parameter when prices
lie between them, suggests the
presence of strong buying and
selling opportunities in the
near-term.
Campbell, Lo, and MacKinlay 1997
Trades Discovery Language - Charts:
Performance Language
7. 8
Standard Definitions
TA SA
General
“based on statistical
analysis of variables such
as trading volume, price
changes, etc., to identify
patterns”
“mispricing of one or
more assets based on
the expected value of
these assets”
Academic
“predict the future
evolution of asset prices
from the observation of
past prices”
“a long horizon trading
opportunity that
generates a riskless
profit”
Too broad / irrelevant
8. 9
My Definitions of TA and SA
Quantitative trading strategies predict future price action
using quantitative methods applied to historic prices.
Technical Analysis develops quantitative strategies:
– for a single market
– on one trade at a time
– based on visual patterns of historic prices formed on charts.
Statistical Arbitrage develops quantitative strategies:
– for a variety of markets
– on a large number of simultaneous trades
– based on statistical analysis applied to historic prices.
10. 12
TA, SA Strengths and Weaknesses
TA SA
Statistical Language No Yes
TA Tools Language Yes No
Visual Charts Yes No
Probabilistic Model No Yes
Attention to real P&L Yes No
Strategies’
Comparison
No Yes
11. 13
Statistical Arbitrage Example
Example: Momentum Strategy
General Results:
Positive for last 60 years in the U.S.
Profitable in major markets with
exception of Japan.
Jarrow et al., Journal of Financial Economics, 2004
12. 14
Two major types of quantitative
strategies
Momentum Strategy:
– If market goes up – Buy.
– If market goes down – Sell.
Mean-Reversion Strategy:
– If market goes up – Sell.
– If market goes down – Buy.
13. 15
Statistical Arbitrage Example
Example: Momentum Strategy
Specific Results:
Time: 1965 to 1989
Markets: NYSE, AMEX, and Nasdaq – ordinary common shares
Strategy Description:
Long stocks in the top return decile and
Short stocks in the bottom return decile.
Strategies based on formation period of 3m, 6m, 9m, or 12m,
and are held for 3m, 6m, 9m, or 12m.
Strategy includes overlapping holding periods.
Portfolio is rebalanced monthly.
Jegadeesh and Titman, Journal of Finance, 1993 : a famous groundbreaking paper on statistical arbitrage
14. 16
Statistical Arbitrage Example
Example: Momentum Strategy
Specific Results:
Returns of all strategies were positive.
All returns were statistically significant except 3/3.
6-month formation period produces returns of about 1% per month
regardless of the holding period.
The best was 12/3 strategy yielding 1.3% per month.
Jegadeesh and Titman, Journal of Finance, 1993
15. 17
Technical Analysis Example
Isakov and Hollistein, Financial Markets and Portfolio Management, 1999
Example: Crossing of Moving Averages
“One of the simplest, oldest and most widely used technical trading
rule is the moving average rule.”
16. 18
Technical Analysis Example
Isakov and Hollistein, Financial Markets and Portfolio Management, 1999
Example: Crossing of Moving Averages
Time: 1969 to 1997
Markets: Stocks from Swiss Bank Corporation Central Index;
includes all available securities of the Swiss stock market.
Strategy Description:
Strategy is to buy the index when the short-term average crosses
above the long-term average,
and sell the index when it crosses below.
17. 19
Technical Analysis Example
Isakov and Hollistein, Financial Markets and Portfolio Management, 1999
Example: Crossing of Moving Averages
Six various scenarios are reported:
(1,200), (1,100), (1,50), (1,30), (1,10), (1,5).
All are profitable.
The best (1,5) strategy produces 24.30% annually, compared to
6.25% of the buy-and hold strategy.
18. 20
Combining TA and SA
Why not marry the formal science of SA with the
hot visual techniques of TA? What’s the risk?
19. 21
Combining TA and SA
Why not marry the formal science of SA with the
hot visual techniques of TA? What’s the risk?
– Isadora Duncan once
said to George Bernard
Shaw that they should
have a child together.
– "Think of it!" she said,
"With your brains and my
body, what a wonder it
would be."
– Shaw thought for a
moment and replied, "Yes,
but what if it had my body
and your brains?"
20. 22
Combining TA and SA
Is it possible to express the main tools of Technical
Analysis in statistical language?
Example: Moving Average
When technicians look at charts of moving averages,
maybe they study the difference between prices and
moving average?
21. 23
A New Look at Moving Average
Let’s assume that price increments,
dPi = Pi+1 – Pi (non-traditional notations)
are independent.
Then (n=4) P4 – MA4 =
P4 – (P4 + P3 + P2 + P1)/4 =
((P4 – P4 ) + (P4 - P3 )+ (P4 - P2 )+(P4 - P1))/4 =
(( dP3 + (dP3 + dP2 )+(dP3 + dP2 + dP1))/4 =
(3dP3 + 2dP2 + dP1)/4, or
(P4 – MA4 )/(3/2) = 1/6 * dP1 + 2/6 * dP2 + 3/6 * dP3
22. 24
A New Look at Moving Average
For a general n
(Pn – MAn )/((n-1)/2) = m =
1/(n*(n-1)/2) * dP1 + 2/(n*(n-1)/2) * dP2 + … + (n-1)/(n*(n-1)/2) * dPn-1
m is an estimate of expected value of price increment (drift).
The weights of dPi are linearly increasing as observations become
more recent.
Drift is the non-random part of price movement.
The main problem in trading is to discover the shift in the drift.
23. 25
A New Look at Moving Average
Conjecture: This weighting scheme is optimal in the sense
that it minimizes the discovery of the shift in the drift.
In other words, if we know that price increments start with the
negative expected value and at some point during the last n
observations switch to a positive expected value, then, given
a fixed probability of making a wrong call, these weights will
beat any other scheme in the expected length of time passed
after the switch before detecting.
A point aside: If the weights are equal, then m becomes an
average of price increments, a standard function in statistics
for hypothesis testing about expected values. From technical
analysis point of view, the signal becomes proportional to the
difference between the current price and the price n time
periods ago, which is called momentum, an important
example of so-called oscillators.
24. 26
New Stat Arb Trading Strategy
based on new interpretation of MA
Given those weights (probabilities), we can
calculate not only m, but also σ , an estimate of
standard deviation of price increments, and
τ = m / σ
Period: 9/10/1997 (since the start of e-Mini S&P
500 trading) to 9/30/2005.
Markets: Continuous e-Mini futures.
Description of strategy: Mean Reversion.
– Take n = 63 (3 months).
– Calculate t = τ √ (n/2), a normalized τ.
– When t >= 0.5, enter short, when t <= 0.25 exit short.
– When t <= -0.5, enter long, when t >= -0.25 exit long.
25. 27
New Stat Arb Trading Strategy
based on new interpretation of MA
Results: Sharpe Ratio = 1.6, Annualized return = 48.2%,
based on initial capital = Margin + Max Drawdown.
Sharpe ratio definition:
(Expected return – Risk-free rate)/ Standard Deviation of returns
Or just
Expected return / Standard Deviation of returns
Example. Spy (risk-free about 1%)
3 Years 5 Years 10 Years
Mean Ann 14.54% 15.78% 9.68%
St Dev Ann 10.13% 9.52% 14.96%
Sharpe Ratio 1.35 1.56 0.67
27. 29
Reducing Noise of Market Prices
by SA and TA
Any quantitative trading strategy normally
tries to reduce the noise before producing
buy/sell signals
Two main approaches of SA:
1. Develop a pricing model and analyze
parameters of the resulting probabilistic
distribution of prices. Example: new model with MA
2. Combine together several markets and
trade the resulting portfolio that will have
less noise. Example: Jegadeesh and Titman
28. 30
Reducing Noise of Market Prices
by SA and TA
Two main approaches of TA:
1. Use an Indicator: a smooth function of
prices.
– Example: Moving Average
2. Another approach is to reformat prices.
– Examples:
Point-and-Figure Charts
Renko Charts
29. 31
Point-and-Figure Chart
Columns consists of a series of stacked X’s (rising) or O’s (falling)
Additional points are added once the price changes by more than
box size
New columns are placed to the right of the previous column and are
only added once the price changes direction by more than a
predefined reversal amount.
Box = 1
Reversal = 3
Day Price Move Reversal
P&F
chart
1 50Start ! 57
2 52 56 X
3 55 55X X
4 53 54X O X
5 5255-52=3 ! 53X O X
6 51 52X O X
7 53 51X O
8 5454-51=3 ! 50X
9 56 49
30. 32
How P&F Charts are used
Trendlines
From tradesignal.com
Support and Resistance
31. 33
Can we use P&F Chart in SA?
Can a formula be found that tells us when P&F has
momentum and when it is mean-reverting?
What this formula will produce when applied to a random
walk?
32. 34
Japanese Candlesticks: Renko Charts
The following charts show Intel as a classic high-low-close bar chart and as
a 2.5-unit Renko chart.
From http://www.marketscreen.com
33. 35
Japanese Candlesticks: Renko Charts
Renko chart is a particular case of Point-and-figure chart with a reversal
amount twice the box size.
You specify a "box size" which determines the minimum price change to display.
* If the closing price rises above the top of the previous brick by at least the box size,
one or more white bricks are drawn in new columns (buy).
* If the closing price falls below the bottom of the previous brick by at least the box
size, one or more black bricks are drawn in new columns (sell).
* The height of the bricks is always equal to the box size.
From http://www.marketscreen.com
34. 37
Japanese Candlesticks as SA
Reference: Pastuchov, Theory Probab. Appl.,
2005
Define for Renko Charts
Ratio = Average (Column Length / Box
Size)
He proved that for a Wiener process (a random
walk)
Ratio ≈ 2
Therefore
If Ratio > 2, the market has momentum
If Ratio < 2, the market has mean-reversion
35. 38
Japanese Candlesticks as SA
He tested a trading strategy based on this formula
Time Period: 2002-2003
Markets: Emini and Nasdaq100 futures, intraday prices.
Result: The ratio varies from 1.7 to 1.9. Both markets are
mean reverting.
36. 39
Proof of the formula
Let’s prove that if prices form a random walk
Average Column Length / Box Size ≈ 2
for Renko Charts.
First we’ll check that in simulation
Then we’ll study an elementary proof
And then I’ll show you a formal proof
37. 40
For a random walk,
Average Column Length / Box Size ≈ 2
Assume box size = 1
The main question: What’s the average
column length in Renko charts for a
random walk?
Random walk: we flip a coin.
Heads means market’s up, Value = 1.
Tails means market’s down, Value = 0.
What’s the average number of trials before
we flip heads after the start?
39. 42
Proofs
Elementary
An average number of trials before first head = an
average number of tails before first head + 1.
p is probability of getting heads. On average, in n throws
you get p*n heads. Therefore, it requires 1/p throws to
expect to get one head.
So, an average number of trials before first head is 1/p.
40. 43
Proofs
Rigorous
p is probability of getting heads. X = the number of
trials before getting first heads.
P(X = k) = (1-p)k-1p
E(X) = 𝑘=0
∞
k(1−p)k−1p = p 𝑘=0
∞
k(1−p)k−1 =
= -p
𝑑
𝑑𝑝 𝑘=0
∞
(1−p)k = -p
𝑑
𝑑𝑝
1
1−(1−𝑝)
= -p
𝑑
𝑑𝑝
1
𝑝
= p
1
𝑝2 =
1
𝑝
41. 44
What have we learned?
SA and TA are different languages dealing with
trading strategies.
TA is visual and analyzes random variables
SA is statistical and analyzes parameters
42. 45
What have we learned?
Some TA strategies can be expressed as SA by
developing probabilistic models and using statistical
analysis.
– Moving averages
– Japanese candlesticks
Can some SA strategies be expressed as TA by finding
the right indicator to chart?
– Simple example: chart the ratio of a pair of securities.
So can TA and SA be combined?
– Almost always yes for a single market with a clear model.
43. 47
Honesty
Hugh Everett in 1956 developed a theory of
parallel universes.
An event that looks strange or impossible to
occur, in our universe, could be explained if the
sample of universes is large enough.
44. 48
Honesty
In trading, if enough strategies are considered, some of them will
become profitable by chance. It does not mean they are worth
pursuing.
Unfortunately, normally there is no way of checking what else was
considered.
Example: Levy(1967) claimed that a trading rule that buys stocks
with current prices that are substantially higher than their average
prices over the past 27 weeks realizes significant abnormal returns.
Jensen and Bennington (1970), however point out that Levy had
come up with his trading rule after examining 68 different trading
rules in his dissertation and because of this expressed skepticism
about his conclusions.
45. 49
Honesty
The greatest problem in developing trading strategies is to
estimate whether the strategy will perform in the future.
Things to check:
– Simplicity of the strategy.
– Number of parameters used in model.
– Uniformity of performance in time.
– How it fits with the portfolio.