Wednesday, December 27, 2006

Matching What You Trade With How You Trade

In several recent posts, I have mentioned that the growing number of ETFs across the "style cube" are providing active market participants with an increasing number of vehicles for trading. A look at recent returns, for example, shows us that value stocks have been outperforming growth and that smaller cap stocks have been outperforming larger cap ones. Just as important, we see patterns of volatility in smaller cap ETFs that may well make them better trading vehicles than their larger, more popular counterparts.

I decided to use a very simple benchmark trading system to evaluate the trading performance of some of the most popular ETFs. On Tuesday, for example, I found 10 ETFs that traded over 3 million shares on the day: QQQQ, SPY, IWM, XLE, OIH, EWJ, XLF, DIA, SMH, and EFA. Notice the growing popularity of small cap trading (IWM) and international trading (EWJ, EFA). Let's see how some of these popular ETFs perform if we simply buy the ETF when it crosses its 20-day moving average to the upside and we sell it when it crosses it to the downside. Such a very simple system should give us a fair number of whipsaw trades, but should also capture nice trending moves.

In the U.S. large caps, of course, we have seen more evidence of mean reversion than trending during the last several years. For example, going back to 2004 (N = 732 trading days), we find that, when the S&P 500 Index (SPY) is above its 5-day moving average *and* above its 20-day moving average (N = 336), the next 10 days in SPY average a loss of -.04% (188 up, 148 down). That is quite an underperformance: The remainder of the occasions in SPY average a 10-day gain of .63% (256 up, 140 down).

Conversely, when SPY has been below its 5-day moving average *and* below its 20-day moving average (N = 194), the next 10 days in SPY average a gain of .77% (124 up, 70 down). A trend following approach in SPY, which would have a trader buying when the index is above its short-term moving averages and selling when the index is below, would have lost considerable money during this bull market.

But with the help of the "performance" feature from the excellent Barchart site, let's actually see how some of the ETFs would have performed since 2005 if we had implemented the simple system described above:

For SPY, we would have had 16 winning trades and 47 losing trades. This would have lost us about 12 SPY points or the equivalent of 120 S&P futures points--during a bull market! The system did catch two large winning trades--it bought in October, 2005 and in July, 2006--but this wasn't enough to make up for a system that had three times as many losing trades as winners.

If we move over to the iShares Emerging Markets ETF (EEM), we find that we had 13 winners since 2005 and 33 losers. Interestingly, however, the system actually made about 25 points over that period. (It started 2005 trading in the 60s). Why? Because the system was able to catch winners that were much larger than the losers. EEM displayed more runs following breaks above and below its moving average than did SPY.

Now let's look at EFA, the iShares MSCI EAFE international ETF. We had 16 winners with our system and 44 losers. That's not at all a favorable ratio, but still the system eked out a little over 5 points of profit. Once again, we saw good sized runs in EFA that simply were not present in SPY--but not ones as pronounced as EEM.

The point of this, of course, is not to trade such a simple system. Indeed, the approach never made more than simple buy-and-hold during the period studied. Rather, we can see that different ETFs display different trending properties that can make the difference between profitability and significant losing. The takeaway message is that *what* you trade should be compatible with *how* you trade.

12 comments:

kalius said...

Your findings might explain why so many new traders and unsussesfull. some books and websites tend to say that MA crosses like these are the holy grail. May it be that the big money in the market knows all the uninformed money is looking for this and they are just using it as their "edge"?

Some unrelated questions:

It would be interesting to hear your opinion of popular indicators like MACD, RSI, MA's, OBV, etc. Do you use any at all, opinions, ideas, etc.

Also both of your sites are great resources, and have very good links. It would be nice to get some link's or resources on learning a bit about futures, like the SP 500 mini's etc, I have been trying to read on the subject but reliable resources are sometimes hard to find.

Thanks!!!!

Brett Steenbarger, Ph.D. said...

Hi Kalius,

Thanks for your observations. The CME website has some good info on futures; do let me know if you have specific interests or needs. The traditional indicators don't test out well, as David Aronson's recent book found out. The problem is that many of the indicators (such as RSI) are so highly correlated with price that they provide no unique information for anticipating market direction.

As a result, I do not ever look at things like MACD, RSI, etc for trading purposes.

Brett

NO DooDahs said...

The test was "close>20dma" and "close>5dma and close>20dma" – hardly a conclusive test of moving average systems, but enough to show index ETF mean reversion on a fast timeframe.

More conclusive tests would look at close versus ma for different ma stepping from 5 to n, with steps every m days. Dual crossovers with and without a close> filter, multiple combinations from 5 to n days with steps every m days. Triple ma systems with the long ma being stepped from 5 to n days (every m day steps) longer than the medium ma, with and without a close>filter. Etc. One must also test initial stop loss levels and trailing stop or exit rules.

Very simple systems can and do work, but one must be exhaustive in testing for their efficacy before giving up on them.

Side note, some commodity futures (and definitely some stocks) are much less mean-reverting than the indices.

Anonymous said...

Hi Brett,

You may have addressed this in an earlier post.

Have you noticed the divergence of the QQQQs relative to the Nasdaq Composite of late? I wonder what a study of this would yield? It seems that when this occurs, a larger move is on the horizon. I wonder which direction...

Thanks,
Marc

Anonymous said...

Try a moving average crossing over a moving average test and use EMA not SMA. By using the EMA you are ahead of 95% of all traders in the world. I like the 8 and 21 EMA for this purpose.

Brett Steenbarger, Ph.D. said...

Hi NO DooDahs,

Sorry for the confusion. I was intending the moving average trade merely as an example of short-term mean reversion, not as a comprehensive test of moving average systems. I think you're right: simple systems can work, but the performance depends both on the tested parameters and the markets being traded. Thanks for the opportunity to clarify.

Brett

Brett Steenbarger, Ph.D. said...

Hi Marc,

That's an excellent observation. My guess is that if NASDAQ strength or weakness is concentrated in the Qs, forward expectations would be more likely to show mean reversion. But that's based on observations of the largest cap ES stocks vs the entire ES and may not apply to the NAZ. Great topic for study; thanks for the idea--

Brett

Brett Steenbarger, Ph.D. said...

Hi Marlyn Trades,

The EMA will be similar to trading a joint very short term moving average with a longer-term one, but is certainly worthy of study in its own right. Once again, from periods 1-20 days out, what you'll find is mean reversion in the large caps, whether EMA or SMA are used. Other indices and especially individual equities may show very different results. Thanks for the observation--

Brett

Brandon Wilhite said...

Dr. Brett,

I believe that your post implies another conclusion I have come to previously. Different markets are different. When most people do system testing, they are looking for something that works across all time frames, all markets, all lengths of backtesting...or at least over a very high percentage. I believe this is their way of addressing the uncertainty of the future.

I too try to be robust in my testing...but, I handle the uncertainty by designing all of my systems to break. I intentionally assume that anything I build today will be invalid at some point in the future. So the question then is how to manage that risk. The answer I've come to is by money management and managing the growth of the position sizing so that when/if a system does blow-up, then I still have something to show for it.

Brandon

Brett Steenbarger, Ph.D. said...

Hi Brandon,

Thanks for the excellent observation. I agree that markets differ greatly in their volatility and trending. Dealing with them separately and being ready for the time when patterns change and systems break makes a lot of sense.

Brett

Shai said...

You may wish to reconsider your conclusions. Most statistical analysis of equity indices show distinct lack of mean reversion (Even on on high frequency data). Conversely, if you conclude that mean reversion is something which definitely occurs you could perhaps design a mean reversion strategy by flipping your buy and sell signals around. Of course it is first neccessary to give a clearer definition of mean-reversion.

Brett Steenbarger, Ph.D. said...

Hello Shai,

Thanks for the comment and the opportunity to clarify. I agree: "mean reversion" may not be the best term to capture my meaning and is open to multiple interpretations. What I'm pointing to is the leptokurtic distribution of market returns and the moderate tendency toward antipersistence, especially at short time frames. In practical terms, there are fewer runs in the market than one would expect to see in a random distribution (hence the large peak of occurrences near the zero mean). Of course, those runs that do occur tend to be larger than those expected in a normal distribution (fat tails). For the trader, that means many short term moves are reversed, but a smaller number turn into "trends". The traders who make markets in the electronic futures are almost exclusively trading by "flipping buy and sell signals around", taking advantage of antipersistence at the shortest time frames.

Brett