MoneyVidya.com Technical Essentials:
Using MACD Indicators to identify trend changes
Tuesday, 07 April 2009 Page 1
Introducing the MACD Indicator
The (MACD) Indicator is a technical analysis method first developed in the 1960s by Gerald Appel, a
prominent author in investment and trading strategy. MACD stands for Moving Average
Convergence-Divergence and is based on the comparison of fast and slow exponential moving
average prices. Proponents of MACD Indicator methodology argue it can be used to identify trend
changes in stocks and indices and therefore can inform trading decisions.
However, recent research has suggested that trading solely on the back of these signals has a
tendency to result in loss making strategies and the methodologies described below are now most
commonly used as part of a more complex strategy or as a monitoring tool rather than a primary
How it works
The first step in deriving MACD Indicators is to plot a slow and a fast exponential moving average
(EMA) of closing prices. The standard method is to use 12 and 26 day periods. The shorter 12 day
EMA gives more weight to recent prices than the longer 26 day measure.
The next step is to calculate and plot the difference between the two exponential moving averages;
MACD = EMA (12) – EMA (26)
A subsequent smoothing is applied by calculating and plotting a Signal line. This is done by taking a
further exponential moving average of the MACD line. The standard is to use a 9 period EMA.
Signal line = EMA (9) of MACD.
The final step is to calculate the difference between the MACD line and the Signal Line. The
standard representation is to plot the MACD and signal lines on top of a histogram which represents
the difference between the two. In the example chart below the top section shows the actual prices
Tuesday, 07 April 2009 Page 2
with the 12 and 26 period EMA lines superimposed. The lower portion shows the MACD line (red),
Signal Line (blue) and the difference between them (histogram)
Basic trading signals - MACD line crossing zero
Because the MACD line is created from the 12-period and 26-period EMA lines, when the MACD
line crosses zero from below, the shorter-term 12-period EMA simultaneously crosses the 26-period
EMA from below. As the shorter 12-period EMA gives more weight to recent prices, when it crosses
the 26 period EMA from below it indicates recent prices have trended higher than less recent ones,
this is seen as a bullish signal.
When the 12 period EMA crosses the 26 period EMA from above, the MACD line will cross zero
from above. This indicates that recent prices have trended downwards and is seen as a bearish
signal. If we apply these signals to the 6 month Nifty chart below we see the following;
Tuesday, 07 April 2009 Page 3
It could be argued that the trading signal identified a bullish trend starting in the 2nd half of March
and a bearish one starting in the 2nd half of May. However it is clear that the trends were identified
long after they had begun. In this example the MACD line cross-over trading signal resulted in a
small loss because the trader would have got into the bull and out of the bear too late.
Tuesday, 07 April 2009 Page 4
MACD Crossing Signal line
An alternative MACD Indicator is the MACD crossing Signal Line. Using this method a buy signal is
generated when the MACD line (red) crosses the MACD Signal Line (blue) from below. Similarly,
when the MACD line crosses the Signal Line from above, a sell signal is generated. Looking at the
same six month Nifty chart we see the following;
Clearly this method identified the same trends as the MACD line crossing zero method. However,
this time the trading signals are generated earlier and resulted in a profit whereas the MACD line
crossing zero trading signals resulted in a loss.
Tuesday, 07 April 2009 Page 5
MACD Divergence and convergence
The previous two sets of trading signals used the MACD and Signal Lines. The third common MACD
indicator relies on the histogram. By looking at the solid bars of the histogram it is easy to identify
two scenarios. Convergence describes the situation where the histogram is shrinking because the
MACD is getting closer to the signal line. Divergence is when the histogram is growing and the
MACD is moving away from the Signal line.
If the MACD histogram is increasing in size (divergence) then difference between the MACD and
Signal lines is increasing. This implies that the underlying stock or index is moving strongly in one
direction. Similarly when the MACD histogram is decreasing in size (convergence) the difference
between the MACD and Signal Line is decreasing. This often implies that the previously strong
trend in the underlying stock or index is weakening or possibly reversing.
Tuesday, 07 April 2009 Page 6
MACD convergence trading signals
When the MACD histogram is below zero and converges towards zero, this implies the strong
downward trend of the underlying stock or index is weakening or possibly reversing. This is seen as
a bullish signal. When the MACD histogram is above zero and begins to converge towards zero, this
implies that the strong upward trend of the underlying stock or index is weakening or reversing.
This is seen as a bearish signal. Applying this method to the same 6 month Nifty chart we see the
In four out of the five situations the MACD indicator was close to identifying the top / bottom of the
trend in the underlying index. However the convergence in July proved to be a false signal because
although the MACD histogram converged towards zero it only crossed it momentarily and the
downward trend of the underlying index continued. This is an example of the MACD indicator
identifying a temporary weakening in the trend rather than a fundamental reversal. Clearly buying
here and then selling on the next sell signal would have resulted in a small loss.
Tuesday, 07 April 2009 Page 7
MACD Health warning
The 6 month Nifty period used in this article was chosen based on the fact that it contained
examples of the 3 types of MACD Indicator and not because the Indicators performed well or badly
in this period. As mentioned in the introduction, trading solely on the basis of MACD indicators has
been shown to result in more losing trades than winning ones.
Because the technique is based on 12 and 26 day exponential moving averages, it is a lagging
indicator and often identifies trends too late for the trader to profit from them. It also often fails to
correctly identify trend changes in volatile market conditions or for volatile assets. It does however
remain a useful monitoring tool for the technical analyst and can inform trading decisions when the
MACD signals are confirmed (supported) by other forms of technical analysis.
Tuesday, 07 April 2009 Page 8