## What is MACD and how to use it to determine market trends and reversals?

March 24, 2023
9m

The Moving Average Convergence/Divergence indicator (MACD), is a trading indicator that measures asset momentum. It appears as a line on a separate chart below a stock chart.

MACD represents the relationship between two Exponential Moving Averages (EMAs): the shorter (12-day) and longer (26-day) EMAs.

The interaction between the two EMAs is called Convergence and Divergence:

• When two averages move toward each other, it is called Convergence.
• When two averages move away from each other, it is called Divergence.

MACD assumes that comparing recent and long-term price movements provides insight into occurring price trends. When the MACD line moves above zero, the stock gains upward (bullish) momentum. When it moves below zero, the stock gains downward (bearish) momentum.

Another vital component of MACD is the signal line, which is typically illustrated as a 9-day EMA of the MACD itself.

The visual representation of both MACD and the signal line is called the MACD histogram. Investors use it to view momentum changes and quickly spot trend reversals.

The histogram may be positive (when the MACD line is above the 9-day EMA) or negative (when the MACD line is below the EMA).

#### How to calculate MACD?

The  MACD oscillator is obtained from the difference of two exponential moving averages, one using a faster period (often 12) and one using a slower period (often 26):

MACD = 12-Period EMA − 26-Period EMA

It is calculated using the following steps:

1.
Calculate the 26-day Exponential Moving Average (EMA) of the closing prices of the asset.

2.
Calculate the 12-day Exponential Moving Average (EMA) of the closing prices of the asset.

3.
Subtract the 12-day EMA from the 26-day EMA to get the MACD line.

4.
Calculate a 9-day EMA of the MACD line to create the signal line.
The formula for calculating the signal line is as follows:

Signal Line = 9-day EMA of MACD

5. Plot the MACD line and the signal line on a chart.

6.
Interpret the MACD and signal line crossovers to identify potential buy and sell signals.

The choice of time periods for both EMAs can be adjusted depending on preferences and the characteristics of the analyzed asset.

#### MACD Divergence

The divergence signal occurs when the cryptocurrency price moves in one direction, but the MACD indicator moves in the opposite direction. Two types of this indicator can be distinguished:

#### MACD Bullish Divergence

Occurs when the price of an asset makes a new low while the MACD indicator makes a higher low.

This pattern suggests that while the price is moving lower, the momentum of the market is actually starting to shift in a positive direction. The MACD bullish divergence can be a strong indication that a potential trend reversal is on the horizon.

#### MACD Bearish Divergence

Occurs when the price of an asset reaches a new high, but the MACD indicator fails to follow suit and instead makes a lower high. This indicates that the bullish momentum may be losing strength. This may signal that a bearish reversal could be imminent.

Traders often look for bearish divergences as a signal to sell or short the asset, in anticipation of a price drop.

#### MACD vs. RSI

MACD (Moving Average Convergence Divergence) and RSI (Relative Strength Index) are technical analysis indicators used to evaluate the momentum and trend of financial assets.

MACD uses the difference between two moving averages (usually 12-day and 26-day) to identify potential buying or selling opportunities.

The MACD line is calculated by subtracting the 26-day exponential moving average (EMA) from the 12-day EMA. A signal line (usually a 9-day EMA of the MACD line) is then plotted to indicate potential buy or sell signals. Traders look for bullish and bearish crossovers between the MACD and signal lines to determine trend shifts.

On the other hand, RSI compares the average price gains and losses of a financial asset over a set period (typically 14 days) to determine if it's overbought or oversold. The RSI oscillates between 0 and 100 and is considered overbought when it's above 70 and oversold when it's below 30.

Traders use RSI to identify potential trend reversals, as divergences between price action and RSI can indicate a weakening trend.

While both indicators can identify potential trend reversals and buy/sell signals, they have different strengths and weaknesses. MACD is generally better at identifying trend shifts and crossovers, while RSI is better at indicating overbought and oversold conditions.

Traders may use both indicators in conjunction with other technical analysis tools to confirm signals and make informed trading decisions.

#### Summary

The Moving Average Convergence/Divergence (MACD) is a trading indicator that measures an asset's momentum through two exponential moving averages (EMAs) of different periods. The MACD line, signal line (a 9-day EMA of the MACD), and MACD histogram are used to spot trend reversals and momentum changes in a stock's chart.

MACD is often compared to Relative Strength Index (RSI) as both technical analysis indicators identify trend shifts and buy/sell signals. MACD identifies trend shifts and crossovers better, while RSI indicates overbought and oversold conditions.

Complete quiz
What is MACD and how to use it to determine market trends and reversals?
Beginner

### Gas fees

Gas fees play a vital role in cryptocurrency transactions, as they are essentially the charges imposed by networks for processing and validating transactions.
Beginner

### Annual Percentage Rate (APR) and Annual Percentage Yield (APY)

Both APR and APY are fundamental terms if you invest in cryptocurrencies. Generally, APR is most beneficial when you borrow, and APY works in your favor if you lend.
Intermediate