Time Series forcasting Flashcards
What is Time Series forecasting
refers to what is observed over time, generally speaking, forecasting aims to estimate how the sequence of observation will continue over time
what are the types of forecasting
- the Explanatory model, where the variables actually capture the reason for the change
Electricity Demand = f (current temperature, strength of economy, population,time of day, day of week,
error). - Time Series model where the prediction of the future is based on past values
Electricity Demand EDt+1= f (EDt, EDt−1, EDt−2, EDt−3,…, error) - mixed-model, a mixture of both
what are the main steps of forecasting
1- initially define the problem what to forecast? 2- father the information 3- Explore the data, trends seasonality 4- choose the adequate fitting model 5- evaluate your forecasting model
why we perform time series decomposition
Decomposition offers a useful abstract model for the data
what are the main time series components
the Trend, the long term increase or the decrease of the data
Seasonality, where the time series is affected by the seasonal factor
cycles similar to trend but lacks a fixed frequency
what are the two types of decomposition
we have additive decomposition yt= St + Tt + Rt
and multiplicative one yt= St × Tt × Rt.
what are the types of adjustment we need to add for the decomposition
this include calendar adjustment for instance sum of daily sales instead of monthly one as Not all month days are actually worked.
how to estimate the trend Cycle
Use the moving average
● m=2k+1, k is number of neighbours
● Every value is replaced by the average of itself and its k nearest neighbourhood
● Results in a smooth trend-cycle component
● Ex: K=2, m=5, the result is called 5-MA
● Averaging is applied using a sliding window
why use a Moving average of Moving average is
since odd-order moving averages is symmetric, while even order ones are not
How to perform additive decomposition
1- compute the trend cycle Tt using MA
2- calculate the detrended series yt− Tt
3- compute the seasonal component for each season, it actually corresponds to the detrended values for that season in all the data
4 - compute the remaining
suggest a simple forcasting
Mean method where all the future data is equal to the average of the history
Naive method, the future is based on the last observed one
Season naive each forecast is equal to the last observed values in the sam season
how can we forecast using decomposition
Seasonality adjusted component A = T + R where R is the remainder component
forecast both the seasonally adjusted one and A
The seasonal component is simply repeated
what are the stationary time series
sort of consistency in the data, where the distribution depends only in difference in time rather than location in time
why it is beneficial to transform time series into a stationary one
This is because the statistical parameters, mean, variance does not vary over the time windows, hence we obtain a better forecast
how to convert time series to stationary
perform a simple difference y i = y i − y i−1 and combine them with a log scale of one
We can also use the second-order differencing, and the obtained data model is y i+1 = y i+ c + e i+1
where e i+1 is the white noise with zero mean