OK, so in this lecture, we are going to discuss Etes for Beginners.
This is the lecture you should watch to gain some intuition behind the techniques in this section,
but you don't necessarily care about how or why it works.
So to recap what we said in the intro, the basic premise of this section is the moving average.
The moving average is a simple concept.
You take a window and slide it across the time series.
And at each point in the Time series, you take the average of all the numbers in that window.
That's called the simple moving average in pendas.
You can do this in just one line of code.
Now, you might think that this is too simplistic for the real world, but in fact, this simple concept
is used for algorithmic trading, for presenting covid counts to the public and so forth.
Now, the simple moving average is, in fact, a bit too simple, one way to view it is it's equally
weighted since each point you, including your average, matters the same amount.
Basically, if you have end points, then each point gets a weight of one over end.
In contrast, we also have the exponentially weighted moving average, which weights each point exponentially
going back in time.
So in this case, we don't have a sliding window, but instead all past data points count.
Going back to the start of your Time series.
The intuition behind this is it's saying Newar points matter more than older points, so they get higher
weights.
But essentially the effect is the same for both the ESMAY and the WEMA.
The output looks like a smoothed out version of the input.
That's the meat tends to lag a bit more, but they both basically do the same thing.
So how can we use the exponentially weighted moving average to actually build a forecasting model?
Well, the simplest method is called a simple exponential smoothing.
Basically, this assumes that your time series fluctuates around some constant value in time.
Therefore, what the model tries to do is it tries to learn what this average value is by using the
WEMA in order to forecast beyond the data.
It simply assumes that the final GWM value will propagate into the future.
And of course, this makes sense according to the assumptions of the model, which is that the TIME
series is a constant value, plus some random noise.
Note that in its terminology, we call this constant value the level.
OK, so the next model we are going to learn about is Holtze linear trend model.
Basically, it's exactly how it sounds.
This is a model that assumes there is a linear trend in your Time series.
Now, how it does this is pretty cool.
It basically uses two exponentially weighted moving averages at the same time.
So you have one moving average for the level and you also have one moving average to learn the trend.
The forecast is then just a linear equation using this level and trend.
You may recall from your high school math studies that the equation for a line is Y equals M, X plus
B or slope multiplied by X value plus intercept.
In this case, our slope is the trend.
Our X value is the number of steps in the forecast and our intercept is the level.
So you can see that with this model, our forecast becomes a line that can go in any direction which
is more powerful than the previous forecast, which had to be a horizontal line.
The next model we will learn about is the full whole winters' model.
This model is a model that adds seasonality.
Basically, it's still the same concepts where we use an exponentially weighted moving average to learn
each component.
That is to say, in addition to the level and trend, we now have yet another moving average to estimate
the seasonal component.
So the seasonal component is assumed to be constant over each season.
So what that means is if I add plus five in May, twenty twenty one, it will also add plus five and
May twenty, twenty two plus five and May twenty, twenty three and so forth.
So that's the basic idea.
The seasonal component is the part of the time series that repeats every season.
The final thing I want to mention in this lecture is that there are different ways to combine each of
these components.
Initially, we assume that each component was additive.
That is the time series value is equal to the level plus the trend plus the seasonal component.
However, it's also possible for any of these relationships to be multiplicative instead.
So, for example, we could have the level times, the trend times, the seasonal component.
Note that this is yet another motivation for why we take the log as a useful transformation for Time
series.
Recall that when you take the log of two variables being multiplied together, it turns into addition.
In other words, the log of a product is equal to the sum of logs.
OK, so that's the basic intuition for each technique we will study.
Thanks for listening and I'll see you in the next lecture.