entekhab.netentekhab.nettrilingual encyclopedia

Moving Average Convergence Divergence

ENGLISHMoving Average Convergence Divergencereference
فارسیمکدیEnglish term retained
کوردیماکدیEnglish term retained
Category
Technical Analysis
Level
Professional

Simple definition

The gap between a fast and a slow exponential average of price, drawn as a line, with its own average on top and the difference between the two shown as bars.

Professional definition

Appel's momentum indicator. The MACD line is the 12-period EMA minus the 26-period EMA; the signal line is a 9-period EMA of the MACD line; the histogram is the MACD line minus the signal line. The 12, 26 and 9 defaults are convention, not the output of an optimisation.

Technical definition

A band-pass filter: subtracting one EMA from another cancels the slow common component and leaves a medium-frequency residual, and taking a 9-period EMA of that residual adds a second lag. Being a difference of prices it is unbounded and not comparable across instruments or price levels without normalising. Zero crossings restate a moving-average crossover and lag accordingly; the histogram is a second difference, so it turns earlier and is correspondingly noisier.

Academic definition

The difference between two exponential moving averages of unequal span, together with a smoothed signal series and the residual between them, used as a momentum measure.

Mechanism

Each EMA centres on a different stretch of recent prices, so their difference measures how far the fast centre has pulled away from the slow one — a reading of acceleration rather than of level. Smoothing that difference and subtracting again gives the histogram, which turns before the line does because it responds to the change in the gap rather than to the gap itself.

In practice

Who uses it
Trend and momentum traders, systematic developers using it as a regime or bias filter, and analysts reading divergence on the histogram.
Why it matters
It isolates the medium-term component of a move from both the slow trend and the fast noise, using two spans and one subtraction.
Limitations
Unbounded, so there is no comparable threshold across instruments; zero crossings lag by construction; and the 12, 26, 9 triple is inherited, so results shift with other spans.

Common mistakes

  • Comparing MACD values across instruments or across price levels.
  • Reading a zero crossing as early when it restates a slower crossover.
  • Changing the spans after seeing the backtest result.

Examples

market

The histogram shrinks for eight sessions while the MACD line is still positive and above its signal. Acceleration has stopped although the two averages have not yet crossed, which is the only sense in which the histogram is earlier.

numeric

With a fast average at 105 and a slow one at 103, the MACD line is 2.0. If the previous signal value was 1.4, the new signal is 1.52 and the histogram 0.48 — a positive but narrowing gap.

Given
  • EMA(12) = 105.0
  • EMA(26) = 103.0
  • previous signal = 1.4
  • signal alpha = 2 / (9 + 1) = 0.2
Steps
  1. MACD = 105.0 - 103.0 = 2.0
  2. signal = 0.2 x 2.0 + 0.8 x 1.4 = 1.52
  3. histogram = 2.0 - 1.52 = 0.48
MACD 2.0, signal 1.52, histogram 0.48

The values are in price units of this instrument. A MACD of 2.0 on an asset priced near 100 is not comparable to a MACD of 2.0 on one priced near 10000.

Mathematical foundation

MACD_t = EMA_{12}(P)_t - EMA_{26}(P)_t, \qquad Signal_t = EMA_{9}(MACD)_t, \qquad Hist_t = MACD_t - Signal_t

Variables

P_tInput price series, conventionally the closeprice units
EMA_{12}, EMA_{26}Fast and slow exponential averages of the price seriesprice units
MACD_tDifference between the two averages at tprice units
Signal_t9-period exponential average of the MACD lineprice units
Hist_tHistogram: MACD line minus signal lineprice units

Procedure

Compute the 12 and 26 period exponential averages of the same price series, each with alpha equal to 2 divided by span plus 1. Subtract the slow from the fast to get the MACD line. Smooth that line with a 9-period exponential average for the signal, then subtract the signal from the line for the histogram.

Worked example

Given
  • EMA(12) = 105.0
  • EMA(26) = 103.0
  • previous signal = 1.4
  • alpha for the 9-period signal = 0.2
Steps
  1. MACD = 105.0 - 103.0 = 2.0
  2. signal = 0.2 x 2.0 + 0.8 x 1.4 = 1.52
  3. histogram = 2.0 - 1.52
MACD 2.0, signal 1.52, histogram 0.48

Interpretation

The line is a price distance: how far the fast average sits above or below the slow one. Its sign restates which average is on top; the histogram says whether that distance is currently growing or shrinking.

Assumptions

  • Exponential smoothing with alpha = 2/(span+1), applied to closes. Platforms that use a simple average for the signal line, or a different input price, produce different values from the same data.
  • The 12, 26 and 9 spans are Appel's convention and are not an optimisation result; any reported performance is specific to that triple.
  • Both averages must be seeded consistently; a short warm-up distorts early values of the line and the signal.
Limits of the formula
  • Unbounded and expressed in price units, so levels cannot be compared across instruments, across time when price has scaled, or against a fixed threshold. Percentage variants exist and are a different indicator.
  • A zero crossing is the same event as the two averages crossing, so it carries the same structural delay.
  • The histogram's earlier turns come from differencing, which amplifies noise; more signals are produced, not better ones.

Related terminology

related
Moving Average Divergence Overbought and Oversold Stochastic Oscillator Golden Cross and Death Cross Timeframe Bollinger Bands
Commonly confused with

Relative Strength Index

RSI is bounded between 0 and 100 and measures the balance of gains against losses. MACD is an unbounded price difference measuring the gap between two averages. Their readings are not on comparable scales.

Sources

Technical Analysis: Power Tools for Active Investors
FT Prentice Hall · 2005 · chapters on the MACD, its construction and the 12-26-9 settings
Print source
Technical Analysis of the Financial Markets
New York Institute of Finance · 1999 · chapter on oscillators, section on the MACD
Print source
Technical Analysis: Modern Perspectives
CMT Association · evidence review for momentum and crossover indicators
https://cmtassociation.org/wp-content/uploads/2019/01/Technical-Analysis-Modern-Perspectives-CMT-Association.pdf URL verified

Editorial status

Draftindustry-conventionv1.02026-11-03

Written, not yet reviewed.

Construction follows Appel's definition; the 12, 26 and 9 spans are recorded as convention rather than as an optimised or validated choice, and no performance figure is quoted. Persian and Kurdish practitioners both use the English abbreviation, so term_status is english-retained in each rather than a coinage.