1
$\begingroup$

In exponential smoothing models, the most recent observation is weighted most heavily, while observations further back receive a smaller and smaller portion of weight. An alpha parameter will inform the exponential decay of weights going back in time.

f[i] = ax[i]
       + a(1-a)(x[i-1])
       + a(1-a)(1-a)(x[i-2])
       + ...

Source

The infinite series of weights will sum to 1. But in practice, how is this evaluated? I can see three possible options:

  1. Have some arbitrary depth cutoff; after x iterations, whether the weight is 0.1 or 0.0001, terminate evaluation.
  2. Have some arbitrary weight cutoff; whenever the weight value is less than 0.001 terminate, whether depth is 10 or 100.
  3. Use sequence/series trick from calculus to reframe the series as a constant that can be solved for.

Of note, I'm particularly interested in Bayesian approach to exponential smoothing, so any insights into how MCMC would solve parameter estimation in exponential smoothing would be of interest to me.

$\endgroup$

1 Answer 1

1
$\begingroup$

This is nicely explained in Forecasting: Principles and Practice by Rob J Hyndman and George Athanasopoulos:

The process has to start somewhere, so we let the first fitted value at time 1 be denoted by $\ell_0$ (which we will have to estimate). Then

$$ \begin{align*} \hat{y}_{2|1} &= \alpha y_1 + (1-\alpha) \ell_0\\ \hat{y}_{3|2} &= \alpha y_2 + (1-\alpha) \hat{y}_{2|1}\\ \hat{y}_{4|3} &= \alpha y_3 + (1-\alpha) \hat{y}_{3|2}\\ \vdots\\ \hat{y}_{T|T-1} &= \alpha y_{T-1} + (1-\alpha) \hat{y}_{T-1|T-2}\\ \hat{y}_{T+1|T} &= \alpha y_T + (1-\alpha) \hat{y}_{T|T-1}. \end{align*} $$

Substituting each equation into the following equation, we obtain

$$ \begin{align*} \hat{y}_{3|2} & = \alpha y_2 + (1-\alpha) \left[\alpha y_1 + (1-\alpha) \ell_0\right] \\ & = \alpha y_2 + \alpha(1-\alpha) y_1 + (1-\alpha)^2 \ell_0 \\ \hat{y}_{4|3} & = \alpha y_3 + (1-\alpha) [\alpha y_2 + \alpha(1-\alpha) y_1 + (1-\alpha)^2 \ell_0]\\ & = \alpha y_3 + \alpha(1-\alpha) y_2 + \alpha(1-\alpha)^2 y_1 + (1-\alpha)^3 \ell_0 \\ & ~~\vdots \\ \hat{y}_{T+1|T} & = \sum_{j=0}^{T-1} \alpha(1-\alpha)^j y_{T-j} + (1-\alpha)^T \ell_{0}. \end{align*} $$

So you would be usually calculating it sequentially, starting from the time 1.

$\endgroup$
3
  • $\begingroup$ Also, I've used Gaussian Process regression to good effect in non-time-series applications before. I wonder- is there a better kernel choice for time-series applications than the popular radial basis kernel? $\endgroup$
    – jbuddy_13
    Commented Jan 19, 2022 at 16:26
  • $\begingroup$ @jbuddy_13 slow as compared to what? To calculate the smoothed values for all your observations you need to run a single for loop over the data. $\endgroup$
    – Tim
    Commented Jan 19, 2022 at 16:29
  • $\begingroup$ I might have implemented the provided formula incorrectly, as it's not functioning as expected. Any thoughts? colab.research.google.com/drive/… $\endgroup$
    – jbuddy_13
    Commented Jan 19, 2022 at 18:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.