Monday, October 22, 2007

EMA statistics - I invent it myself

I used S&P 500 in my analysis of exponential moving average. I took all the history of the S&P 500 daily index numbers (adjusted closing price from Oct 15, 1950 up to Dec 15, 2006) as my data and calculated the 20-day EMA and 200-day EMA.

I found that about 83% of the time, the ratio of the 2 EMAs is between -5% to +10% (ratio is 20-day EMA divided by 200-day EMA, calculated everyday). Over these 56 years of data, there were definitely some bull and bear markets including the boom and bust of tech bubble.

But even included those crazy trading days the ratio is rarely in the range of above 10% or below -5%. In fact, the time that the ratio is above 15% is merely 0.01%. On the other hand, the time that the ratio is below -15% is 2.73%.

You may think I want to tell you the conclusion is: when the 2 EMAs diverge for more than 15% the index should reverse the trend so the 2 EMAs will get close to each other again. If you think so you are only half right.

Base on the statistics definitely the 2 EMAs cannot sustain being far away for too long, but it does not necessarily mean the trend has to reverse from up to down or vice versa. The index just needs to stay flat for enough time, such that the 200-day EMA will catch up with the flat 20-day EMA. After the 200-day catches up with the 20-day, the same trend actually can continue.

Let me try using this idea on China and Hong Kong markets these days. Many people think they went up too fast and too much that they should drop. So, their 2 EMAs maybe diverging too much and not sustainable, but they may not drop back much as some people expect.

But at least I think this EMA statistics still give people some good idea that how fast can an index go. If I see S&P 500's EMAs ratio is sitting at above 15%, I can hardly believe it is not overbought.

No comments: