Monday, October 09, 2006

Seasonality in the S&P 500? A TASC article reexamined

Does monthly seasonality exist in the S&P 500 and other stock indices? These days, everyone seems to believe it does but I wanted to make sure. Some technical analysts were not so convinced back in the early 1990s. For my recent research on the seasonality of the the stock market indices, I have been reading old articles from 1990s issues of Technical Analysis of Stocks and Commodities magazine.

Because of a few statistics classes I took, one article piqued my interest more than others; the author used t-tests and their resulting p-values to determine if any given month in the S&P 500's history was significantly different (that is, statistically different from random) from any other month in the year over the history of the index.

If you have the old issues you can follow along: Technical Analysis of Stocks & Commodities V. 10:8 (339-343): Detecting Seasonality by Lewis Carl Mokrasch, Ph.D.

In his article, Dr. Mokrasch describes the exact Excel layout and formulas he used in examining the seasonality of the S&P. He finds "no evidence for the so-called summer rally or the November to April stock swing." I was curious and skeptical enough to repeat his Excel layout because I had performed my own seasonality analysis in Excel for the major stock market indices only a few weeks earlier and showed vastly different results than those of Mokrasch. My results indicated that there are at least large visual differences in the average returns of certain months and weeks of the year. The old adage of "Sell in May; don't come back till Labor Day," actually would have tended to work most of the years since 1950 according to my analysis.

After a few hours of mimicking Mokrasch's Excel worksheet, I soon discovered why he found no significant differences between the months: The t-tests he performed were comparing the average of one given month (say, all the Januarys from 1961-1990) to the total average of any given month across the entire period tested (the average of all the 480 months from 1961-1990). While this is statistically and mathematically valid, I reasoned that in order to test for monthly seasonality, I needed to compare each month's average to every other month's average, not to the total average of the whole period. For example, wanting to know whether January's average significantly differs from September's average will give you a much different t-statistic and p-value than will comparing January's average to the average of all the months from 1961-1990.

Upon discovering this flaw, I tested each month's average to all of the other individual month's averages (i.e. January compared to February, January compared to March, January compared to April etc.). These results show that there was a very significant difference between many of the individual months. The following chart shows the probabilities that the difference between the averages of any two months is due to chance using Mokrasch's test period of 1961-1990.

(Click to enlarge.)



Therefore, in arguing my case, lower p-values are better; in science, p-values below .05 are generally accepted as "significant." For easy visual examination, I have turned on conditional formatting in Excel so that the darker blue cells stick out as the most significant. As you can see, November, December, January in particular significantly differ from many other months. Here I confirm that September is significantly different from November, December, and January, and show that there are many other significant differences.

If we increase our sample to 1950-2005, and the seasonal effect is still there, we should see even lower p-values. Here's the same chart but with a larger sample:

(Click to enlarge.)



So the answer to the question in the title is an emphatic YES: there is statistically significant seasonality in the S&P 500.

This goes to show that it pays to examine others' results carefully before accepting them as fact. (You should examine mine carefully too! If you have questions, please e-mail me at paul@tradersedgesystems.com or leave a comment.)

To Mokrasch's credit, I should add that his methodology was otherwise very reasoned; the fact that he properly detrended the data and that he used statistical inference testing to examine seasonality in the first place demonstrates his understanding of the issues at hand.

Paul

0 Comments:

Post a Comment

<< Home