# How to Calculate the Exponential Moving Average

To calculate the Exponential Moving Average, you need to obtain complete historical price data of the security you’re analyzing. Here you will find the formula to calculate the EMA.

**Matt Hagemann**Trading Knowledge

Posted June 27th 2020

The formula for the Exponential Moving Average (EMA) is a cumulative calculation which includes all historical price data. Every EMA value of a period takes into consideration the EMA value of its preceding period.

Past values in the calculation have a diminishing weight to the EMA while more recent values have a greater weight.

The exact calculation with the EMA formula is as follows:

Where:

**n**is the number of periods (e.g. 200 for the 200 EMA)**EMA[-1]**is the EMA of the previous period**p**is the price in the current period

## Exponential Moving Average Formula

The smoothing constant **K** applies appropriate weight to the most recent price. It uses the number of periods **n** specified in the EMA. A 20 EMA applies a 9.52% weighting to the most recent price (2 / (20 + 1) = .0952). It is therefore also called a 9.52% EMA.

A 200 EMA applies a 0.995% weighting to the most recent price. Notice that the weighting for the shorter time period is more than the weighting for the longer time period. The weighting drops by half every time the moving average period doubles.

You can use variations of the EMA by using the open, high, low or median price instead of using the closing price by default.

## Same Calculation for Every Time Frame

The formula to calculate the 200 EMA is the same across all time frames, be it the daily, weekly, or even monthly time frame. Do you also know how to trade with the exponential moving average? Consider the moving average bounce trading strategy with a stunning risk-to-reward ratio.

Be sure to use the moving average in multiple time frames to greatly improve your consistency and profitability. The longer the time frame, the more reliable the stocks will react to its 200 EMA.

Trading with moving averages isn’t witchcraft as you can see. There is a ton more I want to teach you about doing this right. It’s all super simple and gets your trading career started instantly. Share your email and I’ll send over a charting setup guide.

## Author Bio

**Matt Hagemann**