Solved – Moving return of exponential moving average — choice of alpha

exponential-smoothingtime series

I have a time series with an exponential moving average and I want to calculate a moving return of the EMA over the last m periods (something like a smoothed moving return).

Let's say:

Y(t) is the value of the time series at time period t

S(t) is the value of an EMA of Y at time period t

Now R(t) is the return of the EMA over the last m time periods:

R(t) = S(t) / S(t-m) – 1

My question is: how many time periods should the EMA calculation use for a given m?
Precisely, if the EMA is calculated using S(t) = alpha * Y(t) + (1-alpha) * S(t-1) and alpha is set by 2/(N+1), then how should N depend on m?

I'm assuming that N should be sufficiently less than m to prevent 'overlap' of Y values that are used in the calculation of S(t) and S(t-m).

Any theories or best practices about this?

Best Answer

N itself is often set in an arbitrary manner that makes sense for the application. Frankly the alpha = 2/(N+1) is also somewhat arbitrary, http://www.itl.nist.gov/div898/handbook/pmc/section4/pmc431.htm suggests instead doing an optimization that minimizes the mean squared error. (Nevertheless, alpha = 2/(N+1) seems to be fairly standard practice.)

So as to how n should depend on m, or vice versa, I say try to find something that makes sense given your particular data and that will help with interpreting your results. I wouldn't worry about overlap too much, as it's not like the data is independent--that's why you do the EMA in the first place.

Related Question