Moving averages are one of the most heavily used technical analysis tools. Moving averages smooth a series of data points.
Moving averages smooth the randomness of a security’s daily price fluctuations to reveal underlying trends.
Moving averages are most commonly calculated using closing prices for a specific timeframe. For example, an hourly chart would use each hour’s closing price and a daily chart would use each day’s closing price.
Exponential moving averages (EMAs) and simple moving averages (SMAs) are the two most popular moving averages. Here, we’ll explain the basics of exponential moving averages.
What is an exponential moving average?
An exponential moving average is the weighted average of a set of data points where new data points receive greater weight in the calculation.
An exponential moving average is a technical indicator that uses a multiplier to give preference to newer data points and reduce lag in responsiveness to price movements. EMAs help traders identify trends.
A number of technical indicators, such as the MACD, use exponential moving averages as a smoothing factor or signal line.
Traders also use multiple EMAs to determine levels of support and resistance, generate buy or sell signals, confirm trading signals, and more.
How to calculate an exponential moving average
To calculate an exponential moving average, first determine the weight of today’s data point in the EMA calculation.
Shorter moving averages have heavier weights for today’s data point.
Second, determine the weight of yesterday’s EMA in the calculation.
Finally, once you’ve calculated the weights, incorporate today’s closing price into the full EMA calculation.
EMAs address the “drop-off effect” caused when the earliest data point rolls off of an SMA calculation.
What is the best exponential moving average length?
50 and 200-day simple moving averages receive the most attention. 12-day and 26-day EMAs are the most popular for short-term traders, and 50-day and 200-day EMAs for longer-term traders.
The periods are somewhat arbitrary and there is little difference between a 25-day EMA and a 26-day EMA. However, the “power of the crowd” is evident when a large number of traders are watching the same timeframe indicators.
Which length is best?
The longer the timeframe, the more data points, the less the reaction to new data points, and the smoother the series. One-day changes in a security’s price do not have a significant effect on longer-length moving averages. That can be good. However, if a stock’s trend changes abruptly, longer exponential moving averages take longer to adapt.
There’s a balance between responsiveness to trend changes and false signals from price outliers.
Moving averages react to data points and are not intended to be predictive like other technical indicators. Moving averages simply follow price action and exponential moving averages react more quickly to new data points than simple moving averages.
The moral of the story: align the moving average length with your trading timeframe. For example, if you are a long-term buy-and-hold investor, the 5-day EMA shouldn’t affect your decisions.
However, short-term traders may still use a long-term EMA, such as the 50-day or 200-day, to identify an overall trend and establish bias. For example, a day trader may only take long trades if the underlying security is above the 200-day EMA.
Using exponential moving averages in stock trading
Traders use EMAs in a number of ways as entry and exit signals.
Support and resistance often rest where two moving averages crossover. So, traders use crossovers for systematic entries and exits. Crossovers are where two moving averages or a moving average and a security’s price cross on a price chart.
For example, a short-term EMA crossing over a longer-term EMA is a mechanical buy signal for many traders. Similarly, a short-term EMA crossing below a longer-term EMA is a sell signal.
One caveat for EMA entry and exit signals is that neutral or sideways price action can generate many low-quality signals leading to whipsaws. EMAs are more useful for entry and exit signals in trending markets. So, EMAs are often used with other momentum signals.
Traders also use EMA as an exit trigger. Long-term EMAs can be used for entry signals and shorter-term EMAs for more responsive exit signals.
For example, trend following traders could enter a position when price crosses above the 26-day EMA and exit the position when price crosses below the 12-day EMA.
EMAs are a tool in many trader’s technical analysis toolbox. Remember to align the moving average length with your trading timeframe.