Market Thoughts
Links | Sitemap | Search:   
  Home  > Commentary  > Archive  > Market Commentary  

Market Timing Made EZ

(Guest Commentary by Bill Rempel July 4, 2007)

Dear Subscribers and Readers,

I hope all our American subscribers are already enjoying their July 4th!  Aside from the KKR IPO filing and Blackstone's announcement of a private equity buyout of Hilton Hotels, this week promises to be a very slow week not just in the stock market but in the currency, interest rate, and commodity markets as well.

As I am writing this paragraph, the Euro/Yen is again near an all-time high (with the GBP/Yen and AUD/Yen cross rates near multi-decade highs).  No doubt, the Yen carry trade is continuing to get more overstretched, but 1) given that semi-annual bonuses in Japan have just been paid, 2) that a significant chunk of that should go overseas, and 3) volume in the currency markets should remain low for the rest of this week, there is a good chance that the Yen carry trade could get even more overstretched over the next few days.  Readers please be careful.

Before we begin our guest commentary this week from Bill Rempel, I would like to again remind readers that David Korn of will write a guest commentary for us this weekend (at long last, our readers will get to take a break from our long weekend newsletters!), as my schedule is very full this weekend.  At this point, however, the topic hasn't been decided yet but as always, David will not disappoint.  Thanks for your help on this, David!

Now, let us get on with our guest commentary.  For those who had wanted to learn more about individual stocks and the art of stock selection, it is again time to see what one of our regular guest commentators, Bill Rempel, has to say about his favorite picks.  Bill is a prolific writing on the stock market and individual stocks and is the author of a very active market blog at:

In this commentary, Bill is going to discuss a simple methodology for timing the stock market via the 60-day and 130-day exponential moving averages.  Bill shows that such a simple methodology would have yield quite satisfactory returns since 1950 and ends his commentary with a discussion on other possible combinations and the possible next steps to take.

Without further ado, following is biography of Bill:

Bill Rempel (aka nodoodahs) is an active poster on the MarketThoughts forum as well as a few others around the web. Bill is a regular, monthly guest commentator on our website (see Bill Rempel on Donegal Group for his last guest commentary). Bill graduated from Caddo Magnet High School (a high school for nerds) back in 1985 and proceeded to learn the hard way when he drank his way out of a scholarship to Tulane later that year. After a few years of sweating for a living, he decided to go back to school, and graduated from LSU-Shreveport in 1995 with a Bachelors in Mathematics - all the while working the overnight shift stocking shelves in a grocery store.

Post-college, Bill has been in the P&C insurance industry as an actuary, product manager, and pricing manager. Bill and his wife Millie are amateur investors with a variety of holdings, but they prefer to buy and hold value investments. In typical "value" style, they live cheap, driving old cars and preferring to save or invest instead of buying fancy "stuff."

Disclaimer: This commentary is solely meant for education purposes and is not intended as investment advice.  Please note that the opinions expressed in this commentary are those of the individual author and do not necessarily represent the opinion of MarketThoughts LLC or its management.

I'll be the first to admit that, in shooting for perfection, I like to take a simple idea and overcomplicate it. A case in point may be my predictive models for the stock market, where I am currently using a variety of different lengths of moving averages, "money flow" indicators, and proximity to various x-period highs and lows in an attempt to determine whether this is the best time to be in the market. If we're willing to settle for "pretty good" instead of shooting for "perfect," broad market timing is so simple that it doesn't even need all four letters it's just EZ.

Techniques Needed

The only technique to learn is the Exponential Moving Average, or EMA. This average is used because it doesn't count every point twice, whereas the SMA does.

As a refresher course, the SMA is just the sum of several price points divided by the number of periods it is watched. Prices of 8, 9, 10, 10, 20, 21, and 22 would have an ending four-day SMA of (10+20+21+22) / 4 = 73 / 4 or 18.25. If the next day was priced at 23, the SMA would jump to 21.5! Note also that the first four days would have an SMA of 9.25, while after the addition of the jump to 20, the 4-day SMA would also move to 12.25. So the last day before the price jumped was counted twice; once when it got there, and once when it went away. Anyone who's figured a rolling four-quarter GDP or CPI increase, or TTM returns for a company, has seen this phenomenon.

To figure an EMA, just start with an SMA of the same period. For example, with 8, 9, 10, 10, you would have a 4-day SMA of 9.25, and call that the first point of the 4-day EMA. Then take the difference between the next point and the prior EMA, or 20 - 9.25 = 10.75, divide that by the period (4), and add it to the EMA. 10.75 / 4 = 2.69, added to 9.25, and the next day's 4-day EMA is 11.94. Continue this calculation in series from the start of the data (or for a year or so before the point you start using it), and your data will match what your favorite graphing software spits out. Or, now that you understand the EMA, you could just use your graphing software. For brevity, I will refer to a four-day Exponential Moving Average as "4ema," with other lengths of averages denoted in a similar way.


This is just one explanation; I am not saying that this combination or usage of EMAs for market timing is perfect, or even that it isthe best that can be done; it is, however, disarmingly simple, and worth expanding on for your own ideas. I invite you to download some data for yourself, and improve upon this method. It can be done.

It might be worth looking at a benchmark return on the S&P 500 (not including dividends) before we dive in. From July 1950 to the present, the index has returned about 8.1% annualized, or 0.031% per trading day. The "trading day" distinction is important, and for convenience, I will use 252 trading days per year.

Short-Term Timing

If you were to start in 1950 with the usage of three moving averages, 4ema, 8ema, and 21ema, you could design a decent short-term trend-following system. Simply go long at the close of any day where it seems they will be in alignment (4ema greater than 8ema greater than 21ema), and exit when it looks as if they won't close in that alignment. This simple, short-term system returns 0.037% per trading day in the market, a significant improvement! The out of market returns for the index are 0.024% per trading day. Annualizing this result, you would get 9.83% for in market and 6.28% for out of market.

This system would have you in market only 52.6% of the time, with an average of 11.5 trades per year, a max of 22 trades in 1993, when it was "in" 64.0% of the time, and a min of 4 trades in 1974, when it was "in" only 11.9% of the time.

If you consider transaction costs and the possibility of following an index-tracker or mutual fund, this is probably not a very good method. After all, it's hard to find competing investments making in excess of 6.28% annualized. This system would have had you in cash for Black Monday, however.

To me, this system is best for traders to decide if they should have a short or long bias on swings or day trades, but is not otherwise that useful. I do think there are better short-term methods than the EMAs. However, look at the power of a simple system and some applied logic (moving averages in rank order equals a trend).

Long-Term Timing

Let's consider the 60ema and the 130ema. Readers of my blog know that I include these EMAs on my standard charts, and you may remember me referring to them as "daily equivalents to the weekly MACD averages" in a previous MarketThoughts article. Here, the recipe will be the same, except that we will hold a position in the S&P 500 only when the previous day's close had the 60ema greater than the 130 ema.

This is probably the most boring exercise in trading that you'll ever see. This "system" made 32 trades in 57 years, with 33 calendar years in which there were no trades! 29 of those 33 years were spent entirely in the market, 4 years (1970, 1974, 2001, and 2002) were spent entirely outside the market. Not so boring anymore?

The most trades the system made was in 1960, where it made five trades. In 22 of the 25 calendar years that the system made a trade, it made one trade only. This is a system that is very suitable for long-term asset allocation accounts, in my opinion. It also allows for the compounding effect of dividends, as being in the market for long stretches would mean that dividends would be received and reinvested.

This system is in the market about 77.4% of the time, and returns 0.035% per trading day in the market (without dividends), or 9.2% annualized. During the time the system was out of market, the S&P 500 would return 0.018% per trading day, or 4.58% annualized. I have not yet assessed what alternative investments had done during the periods where the system was out of market, but it seems likely that one could find 4.6% annualized.

Tweaking the Long-Term Timing for Active Trading

If we were to add to the qualifier that, in addition to a close having the 60ema above the 130ema, that the close of the S&P 500 had to be above the 60ema, we would have substantially more trades, and substantially better results.

This method draws 439 trades in 57 years, or 7.7 per year. It is in the market 61.6% of the time, with an average gain per trading day of 0.041%, or 10.82% annualized. The out of market return for the S&P 500 is 0.015% per trading day, or 3.96% annualized, a relatively easy sum to get. Cash would do that in most years.

This system seems to get whipsawed a lot, but not as much as the 4/8/21 system. It made 21 trades in 2000, and 20 in 1956, 1994, and 2006. Interestingly, this system was out of the market for (and made no trades in) the entirety of 1970, 1974, 2001, and 2002. It would have exited the market after the close of October 14, 1987, and re-entered about a year later, so take that for what it is: it misses the crash, but misses most of the rebound. No model is perfect even Cindy Crawford had a mole.

Here's a glance at the equity curves for the two methods, "buy and hold" versus "close/60ema/130ema." Note that this equity curve includes NO contribution from alternative investments when the system is "out of market," and assumes a starting value of $10,000.

SPX vs Equity

One can tell, visually, that the risk-adjusted return on the system is far better than buy and hold. The time out of market demands that a suitable alternative investment be made in order to make the absolute returns, however, because the 10.82% annualized for being "in market" only 61.6% of the time equates to a lousy absolute return of 6.5% annualized. As you may remember, the absolute market return over the time period was 8.1% annualized, so we lose 1.6 points in order to avoid volatility.

Avoiding volatility can mean a lot to an investor. The human tendency is pull money completely out of a system, at just about the right time for it to rebound, and without a structure for re-investing, this can be disaster.

Here's a graph of maximum drawdown that illustrates the point visually. "Drawdown" is just a word representing how much of your account value gets lost during the trading process.

SPX vs Equity

Notice that the system reached a maximum drawdown of 26% only once, in November of 2000, and it stayed out of market until August of 2003. During that roughly three-year stretch, the equity curve includes NO contribution from alternative investments, when in reality, a trader would receive at the very least the return on cash.

In contrast, the "buy and hold" exceeded that 26% level of drawdown in 1962, 1970, 1974, 1975, 1978, 1982, 1987, and 2001. Wow. Matter of fact, it took "buy and hold" from Jan 1973 to Aug 1980 to bring the equity back to breakeven (neither curve includes dividends). Meanwhile, our simple system was back at breakeven and posting gains in 1976.

Next Steps

There really don't have to be any "next steps." If "good enough" is good enough, and if you have an alternative investment you can analyze, this could be the stopper right here. It could be a signal to switch allocations between bonds, commodities, and stocks. It could be a signal to switch to cash. Your mileage may vary.

Other possible next steps:

(1) Use different lengths for the EMAs and determine if any do a better job than 60 and 130.

(2) Look at different combinations of the close and the EMAs. For example, we looked at "in" with close > 60ema and 60ema > 130ema., and out in all other cases. However, there are FIVE other cases. Think about ranking the close, 60ema, and 130ema with highest being "1." We looked at going long if 1-2-3 and exit otherwise. Other combinations are 1-3-2, 2-1-3, 2-3-1, 3-1-2, and 3-2-1. It is possible that some of those situations/alignments are good positions to go long, or good positions to go short. This is worth investigating specifically, what happens when the 60ema and 130ema are inverted, but the close is above one or both of those averages?  Would this counter-intuitive alignment be typical of a recovery from a bear market or a crash?"  Actually, this combination increases the time in market from 61.6% to 69.0% and increases the average daily return from 0.043% to 0.049%, while out of market declines to 0.005%.

(3) Instead of using the close, one could use a shorter EMA in combination with two longer EMAs for the examination. Again, one can get goofy and look at all the combinations instead of a simple bullish alignment.

I am leaving the rest of the examination to the reader. Just because I've gone quite nuts with this by using a multi-variate regression model doesn't mean that you have to, or that you should listen to my model, even though it incorporates a 60ema/130ema relationship as one of the variables. My model makes mistakes! It would have had me in for Black Monday in 1987, for example. The other factor in doing your own investigation, and not trusting mine, is that if you do your own, you will trust it! And trade it.

Article Tools

Subscribe to this FREE commentary

Discuss this page

E-mail this page to your friends

Printer-friendly version of this page

  Copyright © 2010 MarketThoughts LLC. | Privacy Policy | Terms & Conditions