How Long a Moving Average? Moving averages help identify stock market trends
Moving averages (MAs) are among the oldest, simplest, and most useful tools for traders. They help identify trends and find areas for entering trades. We plot them as lines on price charts, each of whose points reflects the latest average price.
What is the reality behind the moving averages, and what do they measure?
Each price is a momentary consensus of value among market participants, a snapshot of the market crowd at the moment of a trade. What if you show me a snapshot of your friend and ask whether he is an optimist or a pessimist, a bull or a bear? It is hard to tell from a single photo. If you take his snapshot from the same position for 10 days in a row and bring them to a lab, you can get a composite photo. When 10 pictures are superimposed upon one another, the typical features stand out, while the atypi cal fade away. If you start updating that composite each day, you'll have a moving average of your friend's mood. If you lay a string of composite photos side by side, it will be clear whether your friend is becoming happier or sadder.
A moving average is a composite photograph of the market. It adds new prices as they occur and drops old ones. A rising moving average shows that the crowd is becoming more optimistic-bullish. A falling moving average shows that the crowd is becoming more pessimistic- bearish.
A moving average responds not only to the data but to how we con struct it. We must make several decisions to help separate the message of our moving average from the construction noise. First, we need to decide what data we'll use. We need to select the width of our time window- wider for catching longer trends, narrower for catching minor ones. Finally, we need to choose the type of moving average.
What Data to Average? Traders who rely on daily and weekly charts usually apply moving averages to closing prices. This makes sense, because they reflect the final consensus of value, the most important price of the day.
The closing price of a five-minute or an hourly bar has no such special meaning. Day-traders are better off averaging not closing prices, but an average price of each bar. For example, they can average Open + High + Low + Close of each bar, divided by four, or High + Low + Close divided by three.
We can apply moving averages to indicators, such as Force Index (see below). A raw Force Index reflects price changes and volume for the day. Averaging produces a smoother plot and reveals a longer-term trend of Force Index.
How Long a Moving Average? Moving averages help identify trends. A rising MA encourages you to maintain longs, whereas a falling MA tells you to hold shorts. The wider the time window, the smoother is a moving average. That benefit has a cost. The longer a moving average, the slower it responds to trend changes. The shorter a moving average, the better it tracks prices, but the more subject it is to whipsaws, temporary deviations from the main trend. If you make your moving average very long, it will miss important reversals by a wide margin. Shorter MAs are more sensitive
to trend changes, but those shorter than 10 bars defeat the purpose of a trend-following tool.
At the time I wrote Trading for a Living, I was using 13-bar MAs, but in recent years I switched to longer moving averages to catch more important trends and avoid whipsaws. To analyze weekly charts, start with a 26-week moving average, representing half a year's worth of data. Try to shorten that number and see whether you can do it without sacrificing the smoothness of your MA. On the daily charts, start with a 22-day MA, reflecting roughly the number of trading days in a month, and see whether you can make it shorter. Whatever length you decide to use, be sure to test it on your own data. If you track just a handful of markets, you'll have enough time to try different lengths of moving averages until you get smoothly flowing lines.
The width of any indicator time window is best expressed in bars rather than days. The computer doesn't know whether you are analyzing daily, monthly, or hourly charts; it sees only bars. Whatever we say about a daily MA applies to the weekly or the monthly. It's better to call it a 22-bar MA rather than a 22-day MA.
Mathematically savvy traders can look into using adaptive moving aver ages whose length changes in response to market conditions, as advo cated by John Ehlers, Tushar Chande, and Perry Kaufman. Ehlers' latest book, Rocket Science for Traders, delves into adapting all indicators to current market conditions.
What Type of Moving Average? A simple MA adds up prices in its time window and divides the sum by the width of that window. For example, for a 10-day simple MA of closing prices, add up closing prices for the past 10 days and divide the sum by 10. The trouble with a simple MA is that each price affects it twice-when it comes in and when it drops out. A high new value pushes up the moving average, giving a buy signal. This is good; we want our MAs to respond to new prices. The trouble is that 10 days later, when that high number drops from the window, the MA also drops, giving a sell signal. This is ridiculous because if we shorten a simple MA by one day, we'll get that sell signal a day sooner, and if we lengthen it by a day, we'll get it a day later. We can engineer our own signals by fiddling with the length of a simple MA!
An exponential moving average (EMA) overcomes this problem. It re acts only to incoming prices, to which it assigns more weight. It does not drop old prices from its time window, but slowly squeezes them out with the passage of time.
Few people calculate indicators by hand these days-computers do it faster and more accurately. If we decide to look at a 22-bar EMA of clos ing prices, K = 2 / ( 22 + 1 ) = 2 / 23 = 0.087. Multiply the latest closing price by that figure, multiply yesterday's EMA by 0.913 ( i.e., 1 - 0.087 ) , add the two, and arrive at today's EMA. Traders sometimes ask where to get an EMA in the beginning. Begin by calculating a 22-bar simple MA and then switch to the EMA. Most indicators require you to have one or two months of data before they start giving meaningful signals.
Trading Signals The most important message of a moving average is the direction of its slope. When the EMA rises, it shows that the crowd is be coming more optimistic and bullish, which is a good time to be long. When it falls, it shows that the crowd is becoming more pessimistic and bearish. It is a good time to be short.
When a moving average points up, trade that market from the long side. When a moving average points down, trade that market from the short side. As a trader, you have three options: go long, go short, or stand aside. A moving average takes away one of those. When it points up, it prohibits you from shorting and tells you to go long or stand aside. When it points down, it prohibits you from buying and tells you to look only for shorts or stay out. When an EMA starts jerking up and down, it indicates a vacillating, trendless mar-ket; it is better to stop using trend-following methods. Continue to monitor the EMA, but take its signals at a discount until a new trend emerges.
The only time when it is OK to override the message of a moving aver age is when trying to pick a bottom after a bullish divergence between MACD-Histogram (described below) and price. If you do that, be sure to use tight stops. If you succeed, bank your profits but do not think that the rules of the game have changed. A trader who thinks he is above the rules becomes careless and loses money.
Enter long positions in the vicinity of a rising MA. Enter short positions in the vicinity of a falling MA. Use MA to differentiate between "value trades" and
"greater fool theory trades." Most uptrends are punctuated by declines, when prices return to the EMA. When we buy near the moving average, we buy value and can place a tight stop slightly below the EMA. If the rally resumes, we'll make money, but if the market turns against us, the loss will be small. Buying near the EMA helps maximize gains and minimize risks.
If we buy high above the EMA, our actions say, "I am a fool, I am over paying, but I hope to meet a greater fool down the road who'll pay me even more." Betting on the greater fool theory is a poor idea. There are very few fools in the markets. Financial markets do not attract foolish people, and counting on them is a losing proposition.
There are times when wild rallies in high-flying stocks seem to vindi-cate the greater fool theory. Stocks with no assets or earnings can fly on hot air. A value trader who feels he is missing those spectacular moves has a choice. He can stick to his method, soberly saying, "Can't catch them all." Or he may decide, "When living with the wolves, howl like a wolf " and start buying upside breakouts. If you do that, remember, you are now engaged in greater fool theory trading and the only asset sepa-rating you from the manic crowd is your risk control-your stops and money management.
The same rules apply to shorting in downtrends. When you go short on a rally to the EMA, you are selling value-before the market reverses and starts destroying value again. A greater fool theorist shorts far below the EMA-the farther away, the greater the fool.
Use a system of dual moving averages to identify trends and enter posi tions. You may select an EMA that tracks your market well, but it moves so explosively that prices never react back to that EMA, denying you a chance to put on a value trade. To solve this problem, you can add a sec ond moving average. Use the longer EMA to indicate the trend, and the shorter to find entry points.
Suppose you find that a 22-day EMA does a good job identifying trends in your market. Plot it, but then divide its length in half and plot an 11-day EMA on the same screen in a different color. Continue to use the 22-day EMA to identify bull and bear moves, but use pullbacks to the shorter EMA to identify entry points.
Moving averages help identify trends and decide whether to trade long or short. They help mark value areas for entering trades. To find exit points, we turn to our next tool, channels on moving averages.