Technical Analysis: Moving Averages

How to Use Moving Averages


Volatility in price movements makes it hard to read chart patterns. Moving averages can help smooth out these erratic movements and make trends easier to spot. Moving averages are better for accurately reading past price movements since they take the average of past price movements.

Types of Moving Averages

The three most popular types of moving averages are:

  • Simple Moving Averages (SMA),
  • Exponential Moving Averages (EMA), and
  • Linear Weighted Moving Averages.

With moving averages traders can identify short-, medium-, and long-term price trends.

Simple Moving Average

A simple moving average is formed by computing the average price of a security over a specific number of periods. Most moving averages are based on closing prices. A 10-day simple moving average takes the last ten closing prices and divides them by ten. The slope of the moving average can determine the potential direction of market prices.

A 5 day SMA can be referred as 5SMA. A 10 days SMA as 10SMA and such. As the reference period for the calculation increases the smoother the moving average would be. And the smoother a MA is the slower it will react to the price movement.


Simple Moving Average

In the stock chart with both a 9-day and 100-day moving average are shown. The 9-day moving average is more responsive to price changes than the 100-day moving. In general, traders can increase the responsiveness of a moving average by decreasing the period and smooth out movements by increasing the period.

When the moving average is calculated by taking more number of closing prices it give a broader view. This helps in predicting the general direction of its future price. With the use of SMAs, we can tell whether a pair is trending up, trending down, or just ranging.

One problem with SMA is that they are susceptible to spikes.When this happens it gives us false signals and appropriate care has to be taken. Also, the weightage of each closing price considered is equal and this makes it difficult to get a clear understanding of the recent trends.

Exponential Moving Average

The exponential moving average leverages a more complex calculation to smooth data and place a higher weight on more recent data points. While the calculation is beyond the scope of this tutorial, traders should remember that the EMA is more responsive to new information relative to the simple moving average. This makes it the moving average of choice for many technical traders.

Exponential Moving Average

The above chart shows how the EMA (blue line) reacts more quickly than the SMA (pink line) when sudden price movements occur.

Where as SMA are more useful for a general trend in certain cases, exponential moving averages (EMAs) reduce the lag by applying more weight to recent prices. The weighting applied to the most recent price depends on the number of periods in the moving average.

Moving averages
Moving averages

Even though there are clear differences between simple moving averages and exponential moving averages, one is not necessarily better than the other. Exponential moving averages have less lag and are therefore more sensitive to recent prices and recent price changes. Exponential moving averages will turn before simple moving averages as in the figure above.

Simple moving averages, on the other hand, represent a true average of prices for the entire time period. As such, SMAs may be better suited to identify support or resistance levels.

  • When you want a moving average that will respond to the price action rather quickly, a short period EMA is the best way to go.
  • When you want a moving average that is smoother and slower to respond to price action, then a longer period SMA is the best way to go. Gives an idea of the overall trend.
  • When moving averages cross over one another, it could signal that the trend is about to change soon.

There are many forex traders out there who look at these moving averages as key support or resistance. These traders will buy when price dips and tests the moving average or sell if price rises and touches the moving average.The area between moving averages could considered as a zone of support or resistance.

Using both SMA and EMA to make trading decisions is the best way to go about as it gives a more clear picture. Also, it is advisable to consider including SMA and EMA of short and long periods together in the mix of indicators.

Linear Weighted Average

How to Use Moving Averages

Moving averages are helpful for identifying current trends and support or resistance levels, as well as generating actual trading signals.

The slope of the moving average can be used as a gauge of trend strength. In fact, many momentum based indicators (as we will see in the next section) look at the slope of the moving average to determine the strength of a trend. For example, Figure 16 (above) has moving average slopes that clearly show a moderate sideways period between September and October and a significant upswing between December and April.

Many technical analysts often look at multiple moving averages when forming their view of long-term trends. When a short-term moving average is above a long-term moving average, that means that the trend is higher or bullish, and vice versa for short-term moving averages below long-term moving averages.

Moving averages can also be used to identify trend reversals in several ways:

  1. Price Crossover. The price crossing over the moving average can be a powerful sign of a trend reversal. Price crossing above the moving average indicates a bullish breakout ahead.
  2. MA Crossover. Short-term moving averages crossing below long-term moving averages is often the sign of a bearish reversal. Short-term moving average crossover above a long-term moving average could precede a breakout higher.
  3. Longer distances between the moving averages suggest longer term reversals as well. For instance, a 50-day moving average crossover above a 200-day moving average is a stronger signal than a 10-day moving average crossover above a 20-day moving average.


 support and resistance

And finally, moving averages can be used to identify areas of support and resistance. Long-term moving averages, such as the 200-day moving average, are closely watched areas of support and resistance for stocks. A move through a major moving average is often used as a sign from technical traders that a trend is reversing.

Moving Average Convergence Divergence

The MACD, is short for moving average convergence divergence. It is one of the most popular lagging indicators among traders. Lagging indicators confirm the existence of a trend.

So, MACD strategy must be used along with other trading strategies and identification of support and resistance levels is essential. The right combination of lagging and leading indicators can provide you with a real edge in the market.

MACD is built using moving averages like simple moving average and exponential moving averages.


How is it calculated?

Different components that make up the MACD indicator are:

  • MACD line, arrived by subtracting 26 period EMA from the 12 period EMA.
  • 9 period EMA of the MACD line, called the signal line.
  • A center horizontal line placed at value zero.

The MACD line is the fast line and the signal line is the slow line. The histogram shows a divergence between the MACD line and signal line.

How to interpret it?

The MACD indicates the changes in the strength, momentum, and direction of the current market.

Positive Gap

  • When MACD line is above zero, it implies 12 period EMA is trading above the 26 period EMA
  • MACD line is above zero and rising signifies an increasing bullish momentum build up.

Negative Gap

  • When the MACD line is below zero, it implies 12 period EMA is below the 26 period EMA.
  • MACD line is below zero and falling signifies an increasing bearish momentum build up.

The purpose of the signal is to further confirm the changes.

  • Bullish momentum when the MACD crosses above the Signal line.
  • Bearish momentum when the MACD crosses below the Signal line.

Histogram represents the distance between the MACD and its signal line. The zero line often acts as an area of support and resistance for the indicator.

  • When the MACD histogram is above zero (the MACD line is above the signal line) this is an indication that positive momentum is increasing.
  • Conversely when the MACD histogram is below zero this is an indication that negative momentum is increasing.

The higher or lower the histogram goes above or below zero the greater the momentum of the trend is thought to be.

When the MACD line is at or close to the zero line, the indicator fails to give a reliable trend reading. In such situations, other indicators and trading techniques must be used to probably predict the price trends.


Moving averages are a powerful tool for traders analyzing securities. They provide a quick glimpse at the prevailing trend and trend strength, as well as specific trading signals for reversals or breakouts. The most common timeframes used when creating moving averages are the 200, 100, 50, 20, and 10-day moving averages. The 200-day moving average is a good measure for a year timeframe, while shorter moving averages are used for shorter timeframes.

These moving averages help traders smooth out some of the noise found in day-to-day price movements and give them a clearer picture of the trend. In the next section, we will take a look at some of the other techniques used to confirm price and movement patterns.


MCAD Script for Pine editor

//Created by user ChrisMoody 2-9-14
//Created for user ericktatch
//Regular MACD Indicator with Histogram that plots 4 Colors Based on Direction Above and Below the Zero Line

study(title=”CM_MACD-Histogram-Color”, shorttitle=”CM_MACD-Hist-Color”)
source = close
fastLength = input(12, minval=1), slowLength=input(26,minval=1)
fastMA = ema(source, fastLength)
slowMA = ema(source, slowLength)
macd = fastMA – slowMA
signal = sma(macd, signalLength)
hist = macd – signal
//Histogram Color Definitions
histA_IsUp = hist > hist[1] and hist > 0
histA_IsDown = hist < hist[1] and hist > 0
histB_IsDown = hist < hist[1] and hist <= 0
histB_IsUp = hist > hist[1] and hist <= 0

plot_color = histA_IsUp ? aqua : histA_IsDown ? blue : histB_IsDown ? red : histB_IsUp ? maroon : white

plot(hist, color=plot_color, style=histogram, linewidth=4)
plot(macd, title=”MACD”, color=red, linewidth=3)
plot(signal, title=”Signal Line”, color=green, linewidth=3)
hline(0, ‘0 Line’, linestyle=solid, linewidth=2, color=white)

Moving Averages EMA/SMA script for Pine editor

//Created by Robert Nance on 072315

study(title=”Moving Average Colored EMA/SMA”, shorttitle=”Colored EMA /SMA”, overlay=true)
emaplot = input (true, title=”Show EMA on chart”)
len = input(5, minval=1, title=”ema Length”)
src = close
out = ema(src, len)
up = out > out[1]
down = out < out[1]
mycolor = up ? purple : down ? purple : purple
plot(out and emaplot ? out :na, title=”EMA”, color=mycolor, linewidth=3)

smaplot = input (true, title=”Show SMA on chart”)
len2 = input(10, minval=1, title=”sma Length”)
src2 = close
out2 = sma(src2, len2)
up2 = out2 > out2[1]
down2 = out2 < out2[1]
mycolor2 = up2 ? yellow : down2 ? yellow : yellow
plot(out2 and smaplot ? out2 :na , title=”SMA”, color=mycolor2, linewidth=3)

What do you think?

0 points
Upvote Downvote

Total votes: 0

Upvotes: 0

Upvotes percentage: 0.000000%

Downvotes: 0

Downvotes percentage: 0.000000%






Support and Resistance

Support and Resistance

Candlestick Patterns

Japanese Candlestick Patterns 102