Professional Documents
Culture Documents
Definition
A time series is a sequence of observations
taken sequentially in time
An intrinsic feature of a time series is that,
typically adjacent observations are dependent
The nature of this dependence among
observations of a time series is of
considerable practical interest
Time Series Analysis is concerned with
techniques for the analysis of this dependence
https://www.youtube.com/watch?v=s9Fcg
JK9GNI
Ex-Post
The
Forecast Future
Period
Ex-Ante
Forecast
Period
Model Performance
RMSE =(1/n(fi xi)2 - difference
between forecast and actual summed
smaller the better
MAE & MAPE smaller the better
Model Performance
Variance portion - Should be zero
How far is variation of forecast from forecast of
actual series variance?
Non-stationary Series
A non-stationary time series will have a time
varying mean or variance or both
For non-stationary time series, we can study its
behavior only for the time period under
consideration
Each set of time series data will therefore be
for a particular episode
So it is not possible to generalize it to other time
periods
Therefore, for the purpose of forecasting,
non-stationary time series may be of little
practical value
Forecasting
Most statistical forecasting methods
are based on the assumption that the
time series can be rendered
approximately stationary (i.e.,
"stationarized") through the use of
mathematical transformations
A stationarized series is relatively
easy to predict: you simply predict
that its statistical properties will be
the same in the future as they have
been in the past!
Forecasting
The predictions for the stationarized series
can then be "untransformed," by reversing
whatever mathematical transformations
were previously used, to obtain predictions
for the original series
The details are normally taken care of by
software
Thus, finding the sequence of
transformations needed to stationarize a
time series often provides important clues
in the search for an appropriate
forecasting model.
Seasonality
Non-stationary series
De-trend and/or
De-seasonalize
Stationary Series Yt
Residual series WN
Model for Yt
AR, MA, ARMA
Residual series WN
Estimate AR, MA, ARMA parameters
Forecast Xt
(In-sample/Out of sample)
Elimination of Trend
Methods:
(a) Moving Average Smoothing
(b) Exponential Smoothing
(c) Spectral Smoothing
(d) Polynomial Fitting
(e) Differencing k times to eliminate trend
Elimination of Seasonality
Seasonal model without trend: Xt = st + Yt,
E(Yt)=0,.
(a)Classical Decomposition
Regress level variable (Y) on dummy variables (with or without
intercept)
Calculate residuals
Add these residuals to mean value of Y
Resulting series is deseasonalized time series
(b)
Elimination of Trend+Seasonality
Elimination of both trend and seasonal
components in a series, can be
achieved by using trend as well as
seasonal differencing
For example: (1-B)(1-B12)Xt
Stationary Series, Xt
Non-stationary series
De-trend and/or
De-seasonalize
Residual series WN
Stationary Series
Model for stn. series
AR, MA, ARMA
Residual series WN
Estimate AR, MA, ARMA parameters
Forecast Xt after re-transformation
(In-sample/Out of sample)
Autoregressive Process
AR(1) model specification is
Yt = m + Yt-1 + ut
(1 L) Yt = m + ut
Yt = (1+ L+ 2L2 +.)(m + ut)
Autoregressive Process
Yt = (1++2+)m+ (ut+ ut-1+2ut-2+)
E(Yt) = (1+ + 2+)m
Autoregressive Process
AR(2) Process:
yt = 1 yt-1 + 2 yt-2 + ut
AR(p) Process:
yt = 1 yt-1 + 2 yt-2 + .+ p yt-p + ut
yt = p yt-p
Defining the AR polynomial
(L) 1L pL p
we can write the AR(p) model concisely as:
(L)yt = ut
Autoregressive Process
It is sometime difficult to distinguish
between AR processes of different orders
solely based on correlograms
A sharper discrimination is possible on the
basis on partial autocorrelation coeff
For an AR(p), PACF vanishes for lags
greater than p. while, ACF of an AR(p)
decays exponentially
The single
negative spike at
lag 1 in the ACF
is an MA(1)
signature
ARMA Process
We can put an AR(p) and an MA(q) process
together to form the more general ARMA(p,q)
process:
yt y t-1pyt-p ut + ut-1 qutq
where {ut} WN(0, 2).
By definition, we require that {yt} be stationary.
Using the compact AR & MA polynomial notation,
we can write the ARMA(p,q) as:
(L)yt (L)ut{ut}WN(0, 2)
ARMA Process
For stationarity and invertibility, we require
as before, that all roots of (L) and (L) be
greater than 1 in magnitude
AR & MA are special cases: an
AR(p)=ARMA(p,0), and an
MA(q)=ARMA(0,q)
ACF & PACF both decay exponentially
Sample ACF/PACF
For an AR(p) the ACF decays geometrically, and the
PACF is zero beyond lag p. The sample ACF/PACF
should exhibit similar behavior, and significance at
the 95% level can be assessed via the usual
1.96 n
bounds
For an MA(q) the PACF decays geometrically, and the
ACF is zero beyond lag q. The sample ACF/PACF
should exhibit similar behavior, and significance at
the 95% level can also be assessed via the 1.96/n
bounds
For an ARMA(p,q), the ACF & PACF both decay
exponentially.
Examining the sample ACF/PACF therefore can serve
only as a guide in determining possible maximum
values for p & q to be properly investigated via AICC.
Sample ACF/PACF
The PACF shows a sharper "cutoff" than the
ACF
In particular, the PACF has only two significant
spikes, while the ACF has four
Thus, the series displays an AR(2) signature
If we therefore set the order of the AR term
to 2 i.e., fit an ARIMA(2,1,0) model--we obtain
the following ACF and PACF plots for the
residuals
AIC 2 log L ,, 2 2 p q
Unit root
ADF Tests-Eviews
To begin, double click on the series name to open
the series window, and choose View/Unit Root
Test
Specify whether you wish to test for a unit root in
the level, first difference, or second difference of
the series
Choose your exogenous regressors.
You can choose to include a constant, a constant and
linear trend, or neither
ARIMA Models
An integrated process Xt is designed
as an ARIMA (p,d,q), if taking
differences of order d, a stationary
process Zt of the type ARMA (p, q) is
obtained.
The ARIMA (p, d, q) model is expressed by the function
Zt = 1 Zt - 1 + 2 Zt - 2 + ..+ p Zt - p + ut - 1 ut 1 - 2 u t 2 - q u t q
Or
(L) (1 L) dX t = (L) ut
Diagnostic checking
One should also examine whether the residues
of the model appear to be white noise process
Forecasting.