Skip to content
All library documents

Deriving EMA Average Data Age and the 2/(N+1) Smoothing Rule

Article Quant Q&A · Author: MBdr

Summary

The note explains why an exponential moving average can be matched to an N-period simple moving average by equating their average data ages. EMA observations k periods old receive weights αβ^k, where β = 1 − α. The simple moving average has an average age of (N − 1)/2, while the weighted EMA average age is β/α.

To bridge the series calculation, it uses the closed form for the sum of kβ^k, which is β/(1 − β)^2 when the series converges. Substituting 1 − β = α gives the EMA age β/α; equating this to the simple average age yields α = 2/(N + 1). The explanation is mathematical rather than empirical: it establishes a correspondence in average observation age, not that the two filters behave identically or that this parameter is optimal for every trading use.

Key ideas

  • EMA average data age is computed by weighting each observation's age by its exponential weight.
  • The geometric power series involving kβ^k sums to β/(1 − β)^2 when it converges.
  • Using β = 1 − α reduces the EMA's average data age to β/α.
  • Matching that age to the simple moving average's age yields α = 2/(N + 1).
  • The matching criterion equates average age, not the full behavior of the two averages.

Tags

Full text
# Exponential Moving Average Data Set Average Age


# Exponential Moving Average Data Set Average Age












Why is the smoothing coefficient of the EMA (exponential moving average) calculated as:

$${\displaystyle \alpha =2/(N+1)}?$$

Brown R.G, on page 107 of "Smoothing, forecasting and prediction of discrete time series (1963)" goes about giving an explanation using the following folowing derivation for what he calls the average age of the data set:

(1) $$avg=0\alpha+1\alpha\beta+2\alpha\beta^2+...$$ (2) $$avg=\alpha\sum_{k=0}^{\infty}k\beta^k$$ (3) $$avg=\frac{\beta}{\alpha}$$

He then goes about saying that if want the exponential average age of the data set (3) to be the same as the simple (N-datapoints) moving average you just need to solve the equation:

$${\displaystyle \beta/\alpha =(N-1)/2}?$$

Or in plain english:

The exponential average age of the data = simple N average age of the data.

It's all fine but I cannot bridge the gap between equations 2 and 3, how did he solve the power serie into that fraction?

Note:

"The average age is the age of each piece of data used in the average, weighted as the data of that age would be weighted. In the exponential smoothing process, the weight given data k periods ago is is:

$$\alpha\beta^k, \beta=(1-\alpha)$$

## Answer by Pleb (score 4, accepted)

https://quant.stackexchange.com/a/68944

## Bridging the gap between equation 2 and 3:

Let us use the fact that the infinite series $\sum_{k=0}^\infty k \cdot \beta^k$ has a closed-form solution given by (see this post for proof):

$$\sum_{k=0}^\infty k \cdot \beta^k = \frac{\beta}{(1-\beta)^2},$$

when $|\beta| = |1-\alpha|<1$ or $\alpha < 1$, for the infinite series to converge to the above result.

Now, let us calculate the average in a few more steps:

\begin{align} \bar{k} &= \alpha \sum_{k=0}^\infty k \cdot \beta^k \\ &= \alpha \cdot \frac{\beta}{(1-\beta)^2} \\ &= \alpha \cdot \frac{\beta}{\left(1-(1-\alpha)\right)^2}\\ &= \alpha \cdot \frac{\beta}{\alpha^2}\\ &= \frac{\beta}{\alpha} \end{align}

I hope this clarifies some things.

Shown in full with attribution under the source's licence. Licence: CC BY-SA 4.0 (Stack Exchange)

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.