0% found this document useful (0 votes)
62 views

TS Chap 2

Uploaded by

samysahhile
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
62 views

TS Chap 2

Uploaded by

samysahhile
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 105

Type author

Samuel name/s
using here
Carter etal.

Chapter Two:
Introduction to basic regression
Chapter
analysis heading
with time series data
Time series Data Analysis: Objectives of the chapter

After successfully completing this chapter you are able to:

• Describe general behavior of time sires data


• Explain the difference between stationary and non-
stationary time series data
• Understand the concept of spurious regression
• Perform unit root tests
• Understand the concept of integrated processes
• Explain the concept of co-integration
• Test for existence of co-integration
• Run VCM

1
Time series Data Analysis: Nature of TS data

1. Temporal ordering
• A TS data set is provided in order of time (chronological)
For example: 2020 immediately precede the data for 2021 and
so forth.
• The past can affect the future but not the future.
2. Stochastic process
 A stochastic process is just a sequence of random variables
indexed by time.
In TS stochastic is a “synonym for random”
 when we collect a TS data set, we obtain one possible
outcome, or realization of the stochastic process.

1
Time series Data Analysis: Nature of TS data

 Therefore, in a TS data set we can only see a single realization,


why?
• Because we cannot go back in time and start the process again
What if time travel is possible?
We would generally obtain a different realization for the stochastic
process and this is why we think of TS data as an outcome of
random variable.
Comparing it with cross sectional data
If you take different samples from your population you get
different outcomes for the interest variable, and this is what
makes OLS estimators a random estimate.

1
Time series Data Analysis: Nature of TS data

MON T H T H H T T T .

TUS H T T T T H T H .

WED T H H T T H T H .

THR H T T T T H T T .

FRI T T T H H T H T .

SAT H H H H H T H T .

SUN T H H T H H T T .

Example: Assume a person flipping a coin from Monday to Sunday, what


would be the outcome of his action? If ordered without replacing,
𝑛 7
= 𝑛! 𝑟! 𝑛 − 𝑟! = = 7! 2! 5! = 21
𝑟 2
1
Time series Data Analysis: Nature of TS data

MON T H T H H T T T .
A
TUS H T T T T H T H .

WED T H H T T H T H .

THR H T T T T H T T .

FRI T T T H H T H T .

SAT H H H H H T H T .

SUN T H H T H H T T .

 This is a stochastic process a (set of all possible realizations)


and it plays the role of population.
A is the realization of a stochastic process
1
Time series Data Analysis: Nature of TS data

 The following two natures are not true for all time TS data
3. Trend time series
• Many economic variables have a tendency of growing up
overtime.
• Considering existence of time trend in TS is important while
making a casual inference among a TS data,
• if not we will face a problem of Spurious regression
The trend in a TS can be:
o Deterministic
Or
o Stochastic

1
Time series Data Analysis: Nature of TS data

4. Seasonality
• Often TS data exhibits some periodicity.
Example: in monthly data retail sales will tend to jump in
months of holidays.
• Seasonality can be dealt with adding a set of seasonal
dummies in our regression model.

1
Time series Data Analysis: Some examples of TS Models

1. Static model
• If y and 𝑧 are a TS variables and the data are dated
contemporaneously, we have
𝑦𝑡 = 𝛼0 + 𝛼1 𝑧𝑡 + 𝑢𝑡
• We call it a static model because we are modeling a
contemporaneous relationship between the two.
• We use it when we believe that the change in our explanatory
variable has an immediate effect on our dependent variable.
∆𝑦𝑡 = 𝛼1 ∆𝑧𝑡
• Naturally, we can have several explanatory variables in a static
regression model.

1
Time series Data Analysis: Some examples of TS Models

• We can use it to model trade offs (static phillip curve)


𝑖𝑛𝑓𝑡 = 𝛼0 + 𝛼1 𝑢𝑛𝑒𝑚𝑝𝑡 + 𝑢𝑡

1
Time series Data Analysis: Some examples of TS Models

2. Finite Distributed lag Model (FDL)


• It is a modification of the static model, where the explanatory
variables are allowed to influence the dependent variable with
a time lag.:
𝑦𝑡 = 𝛼0 + 𝛿0 𝑧𝑡 + 𝛿1 𝑧𝑡−1 + ⋯ + 𝛿𝑞 𝑧𝑡−𝑞 + 𝑢𝑡
is an FDL of order q, where q is finite.
Example: The fertility rate may depend on the tax value of a
child, but for biological and behavioral reasons, the effect may
have a lag,.
𝑔𝑓𝑡𝑡 = 𝛼0 + 𝛿0 𝑝𝑒𝑡 + 𝛿1 𝑝𝑒𝑡−1 + 𝛿2 𝑝𝑒𝑡−2 + 𝑢𝑡

1
Time series Data Analysis: Some examples of TS Models

Where: 𝑔𝑓𝑡𝑡 is general fertility rate (children born per 1, 000


women in year 𝑡) and 𝑝𝑒𝑡 is tax exemption in year 𝑡.
• If there is a one time shock in a past period, the dependent
variable will change temporarily by the amount indicated by
the coefficient of the corresponding lag.
• Consider FDL of order 2
𝑦𝑡 = 𝛼0 + 𝛿0 𝑧𝑡 + 𝛿1 𝑧𝑡−1 + 𝛿2 𝑧𝑡−2 + 𝑢𝑡
• at time 𝑡, 𝑧 increases by one unit from 𝑐 to 𝑐 + 1 and then
reverts to its previous level at time 𝑡 + 1(temporary change):
… , 𝑧𝑡−2 = 𝑐, 𝑧𝑡−1 = 𝑐, 𝒛𝒕 = 𝒄 + 𝟏, 𝑧𝑡+1 = 𝑐, 𝑧𝑡+2 = 𝑐 … . .

1
Time series Data Analysis: Some examples of TS Models

Then by setting the errors to be zero,


𝑦𝑡−1 = 𝛼0 + 𝛿0 𝑐 + 𝛿1 𝑐 + 𝛿2 𝑐
𝑦𝑡 = 𝛼0 + 𝛿0 (𝑐 + 1) + 𝛿1 𝑐 + 𝛿2 𝑐
𝑦𝑡+1 = 𝛼0 + 𝛿0 𝑐 + 𝛿1 (𝑐 + 1) + 𝛿2 𝑐
𝑦𝑡+2 = 𝛼0 + 𝛿0 𝑐 + 𝛿1 𝑐 + 𝛿2 (𝑐 + 1)
𝑦𝑡+3 = 𝛼0 + 𝛿0 𝑐 + 𝛿1 𝑐 + 𝛿2 𝑐
• So
𝑦𝑡 − 𝑦𝑡−1 = 𝛿0
i.e., 𝛿0 is the immediate change in y due to to the one unit increase in 𝑧
At time 𝑡, and usually called impact propensity or impact multiplier.

1
Time series Data Analysis: Some examples of TS Models

• Similarly
𝑦𝑡+1 − 𝑦𝑡−1 = 𝛿1
Is change in 𝑌 one period after the temporary change, and
𝑦𝑡+2 − 𝑦𝑡−1 = 𝛿2
Is change in 𝑦 two periods after the temporary change.
 At time 𝑡 + 3, y has reverted back to its initial level: 𝑦𝑡+3 = 𝑦𝑡−1
because only two lags of 𝑧 appears in the FDL model.
 In summary,

𝜕𝑦𝑡+𝑗
𝛿𝑗 =
𝜕𝑧𝑡
Lag distribution: 𝛿𝑗 is a function of 𝑗, which summarizes the dynamic
effects that a temporary increase in 𝑧 has on y
1
Time series Data Analysis: Some examples of TS Models

• When can also graph the lag distribution, to summarize the dynamic effect
that a temporary increase in 𝑧 has on y.
the largest effect is at the first lag. After that, the effect starts to vanishes (if
the initial shock was transitory).

1
Time series Data Analysis: Some examples of TS Models

• If there is a permanent shock in a past period, i.e., the explanatory


variable permanently increases by one unit, the effect on the
dependent variable will be the cumulated effect of all relevant lags.
This is a long-run effect on the dependent variable
• At time 𝑡, 𝑧 permanently increases by a unit form 𝑐 to 𝑐 + 1:
𝑧𝑠 = 𝑐, 𝑠<𝑡 and 𝑧𝑠 = 𝑐 + 1, 𝑠≥𝑡
Then:
𝑦𝑡−1 = 𝛼0 + 𝛿0 𝑐 + 𝛿1 𝑐 + 𝛿2 𝑐
𝑦𝑡 = 𝛼0 + 𝛿0 (𝑐 + 1) + 𝛿1 𝑐 + 𝛿2 𝑐
𝑦𝑡+1 = 𝛼0 + 𝛿0 (𝑐 + 1) + 𝛿1 (𝑐 + 1) + 𝛿2 𝑐
𝑦𝑡+2 = 𝛼0 + 𝛿0 (𝑐 + 1) + 𝛿1 (𝑐 + 1) + 𝛿2 (𝑐 + 1)
𝑦𝑡+3 = 𝑦𝑡+2
1
Time series Data Analysis: Some examples of TS Models

• With a permanent increase in 𝑧, after one period, y will increase


by 𝛿0 + 𝛿1 , and after two periods, 𝑦 will increase by 𝛿0 + 𝛿1 + 𝛿2
and then stay there.
 The sum of the coefficients on current and lagged 𝑧, is the long
run change in 𝑦 given a permanent increase in 𝑧, and is called
long run propensity (LRP) or long run multiplier.

In summary, in a FDL model of order 𝑞,

𝜕𝑌𝑡+𝑞 𝜕𝑌𝑡+𝑞
𝐿𝑅𝑃 = 𝛿0 + 𝛿1 + 𝛿2 + ⋯ + 𝛿𝑞 = +⋯+
𝜕𝑧𝑡 𝜕𝑧𝑡+𝑞

1
Time series Data Analysis: Some examples of TS Models

• the lag distribution can be plotted by graphing the (estimated) 𝛿𝑗 as


a function of 𝑗.
o For any horizon 𝑕 , we can define the cumulative effect as
𝛿0 + 𝛿1 + ⋯ + 𝛿ℎ , which is interpreted as the change in the
expected outcome 𝑕 periods after a permanent, one-unit increase
in 𝑥.
o Once the 𝛿𝑗 have been estimated, one may plot the estimated cumulative
effects as a function of 𝑕.
o The LRP is the cumulative effect after all changes have taken
place; it is simply the sum of all of the coefficients.

1
Time series Data Analysis: Some examples of TS Models

Example: suppose that 𝑖𝑛𝑡𝑡 = 1.6 + 0.48𝑖𝑛𝑓𝑡 − 0.15𝑖𝑛𝑓𝑡−1 +


0.32𝑖𝑛𝑓𝑡 , where 𝑖𝑛𝑡 is an interest rate and inf is the inflation rate.
What are the impact and long run propensities?
• We can have more than one explanatory variable appearing with
lags, or we can add contemporaneous variables to a FDL model.

1
Time series Data Analysis: Some examples of TS Models

3. An Autoregressive Model (AR)


 An AR model, An autoregressive process, is one where a variable
𝑦 depends on past values of itself.
o The general representation with 𝑝 lagged values, an
autoregressive model (process) of order 𝑝, 𝐴𝑅(𝑃) is given by:
𝑦𝑡 = 𝛼0 + 𝛾0 𝑦𝑡−1 + 𝛾1 𝑦𝑡−2 + ⋯ + 𝛾𝑃 𝑦𝑡−𝑃 + 𝑢𝑡
 AR models can be used to describe the time paths of variables and
capture their correlations between current and past values; they are
generally used for forecasting.
o Past values are used to forecast future values.

1
Time series Data Analysis: Some examples of TS Models

3. An Autoregressive Distributed Lag Model (ARDL)


 A more general model that includes both finite distributed lag
models and autoregressive models as special cases is the
autoregressive distributed lag model
𝑦𝑡 = 𝛼0 + 𝛾0 𝑦𝑡−1 + ⋯ + 𝛾𝑃 𝑦𝑡−𝑃 + 𝛿0 𝑥𝑡 + ⋯ + 𝛿𝑞 𝑥𝑡−𝑞 + 𝑢𝑡
This model, with 𝑝 lags of 𝑦, the current value of 𝑥, is abbreviated as an
𝐴𝑅𝐷𝐿(𝑝, 𝑞) model.
 These models are used for both forecasting and policy analysis.
Read about
Infinitely distribute lag model
Moving average model

1
Time series Data Analysis: Stationary and Non-stationary TS

• On the Graph the GDP variable displays up ward trending behavior.


• Inflation rate appears wondering up and down with no discernable pattern or trend.
 The figures on the RHS are change of each variable on the LHS
1
Time series Data Analysis: Stationary and Non-stationary TS

o The TS of the changes on the RHS display a behavior that can be


described as irregular ups and downs.
o While change in inflation rate appear to fluctuate around a
constant value, the change in GDP variable appears to fluctuate
around up ward trend.

Which data series represents stationary variables and which are observations
on non stationary variables?

1
Time series Data Analysis: Stationary stochastic process

o Broadly speaking stationarity implies that the distribution of TS


variables does not change overtime.
Formally,
A time series 𝑦𝑡 is stationary if its mean and variance are constant
overtime, and if the covariance between two values of 𝑦𝑡 from the series
depends only on the length of time separating the two values and not on
the actual time the variables are observed.
𝐸 𝑦𝑡 = 𝜇
𝑣𝑎𝑟 𝑦𝑡 = 𝐸(𝑦𝑡 − 𝜇)2 = 𝜎 2
𝑐𝑜𝑣 𝑦𝑡 , 𝑦𝑡−𝑠 = 𝐸 𝑦𝑡 − μ 𝑦𝑡−𝑠 − 𝜇 = 𝛾𝑠

1
Time series Data Analysis: Stationary stochastic process

o We observe that the two moments are time invariant.


o This kind of stationarity is known as weakly stationarity process or
Covariance stationarity.
o Such a TS has a property of mean reversion i.e., it will tend to
return to its mean and fluctuate around it.
Note: A TS is strictly stationary if all the moments of its
probability distribution are time invariant.

1
Time series Data Analysis: Stationary stochastic process

o Let 𝑦𝑡 be a particular realization modeled using a univariate TS


model.
o i.e. 𝑦𝑡 is stochastic process were a it is related to the its past
values and current and past error terms.
o Such models does not contain ay explanatory variables.
o AR (1) model, is a useful univariate TS model for explaining the
difference between stationary and non stationary series.
o Hence, before embarking on exploring a new concept let explore
what a stationary TS looks using AR(1) model:

1
Time series Data Analysis: Stationary stochastic process

Our AR(1) is :
𝑦𝑡 = 𝜌𝑦𝑡−1 + 𝑣𝑡 , 𝜌 <1
Where the error term is a white noise (purely random)
𝑣𝑡 ~𝐼𝐼𝐷 𝑂, 𝜎 2 ; 𝐸 𝑣𝑡 = 𝜎 2 ; 𝐶𝑜𝑣 𝑣𝑡 , 𝑣𝑡−1 = 0
Note: in the context of TS models the error terms are known as shocks or
Innovations.
o The assumption 𝜌 < 1 implies that 𝑦𝑡 is stationary.
o In general, the model implies each realization of random variable 𝑦𝑡
contains the portion 𝜌 of last period value 𝑦𝑡−1 plus an error 𝑣𝑡 drown
from the a distribution with mean zero and variance 𝜎 2 .
o To show 𝑦𝑡 is stationary let follow a recursive substitution

1
Time series Data Analysis: Stationary stochastic process

o Conceder the value of 𝑦𝑡 at a time 𝑡 = 1 then its value at time 𝑡 = 2


and so on…
o These values are
𝑦1 = 𝜌𝑦0 + 𝑣1
𝑦2 = 𝜌𝑦1 + 𝑣2 , 𝑦2 = 𝜌 𝜌𝑦0 + 𝑣1 + 𝑣2 , 𝑦2 = 𝜌2 𝑦0 + 𝜌𝑣1 + 𝑣2
………

𝑦𝑡 = 𝑣𝑡 + 𝜌𝑣𝑡−1 + 𝜌2 𝑣𝑡−2 + ⋯ + 𝜌𝑡 𝑦0 = 𝜌 𝑠 𝑣𝑡−𝑠 + 𝜌𝑡 𝑦0


𝑠=0
The mean of 𝑦𝑡
𝐸 𝑦𝑡 = E 𝑣𝑡 + 𝜌𝑣𝑡−1 + 𝜌2 𝑣𝑡−2 … … . . = 0

1
Time series Data Analysis: Stationary stochastic process

o This is because the error tem has a mean zero and 𝜌𝑡 𝑦0 is


negligible for large 𝑡.
∞ 𝑗 2 1
o For an infinite series if 𝑎 < 1, 𝑦0 = 𝑗=0(𝑎 ) = ,
1−𝑎2

o Hence the variance of 𝑦𝑡 is:

𝑡−1 𝑡−1

𝑣𝑎𝑟(𝑦𝑡 ) = (𝜌 𝑠 𝑣𝑡−𝑠 )2 = 𝜌 𝑠 2 𝐸(𝑣𝑡−𝑠 )2


𝑠=0 𝑠=0
Using variance definition:

𝑡−1 2
𝜎
𝑣𝑎𝑟(𝑦𝑡 ) = 𝜌 𝑠 2 𝐸(𝑣𝑡−𝑠 )2 =
1 − 𝜌2
𝑠=0

1
Time series Data Analysis: Stationary stochastic process

o the covariance between two values of 𝑦𝑡 is:

𝜌𝜎 2
𝛾𝑠 = , 𝑖𝑡 𝑑𝑒𝑝𝑒𝑛𝑑𝑠 𝑜𝑛 𝑠
1 − 𝜌2
o 𝐴𝑅(1) is a classic example of stationary process with mean zero and
covariance which depends on the length of time difference between the
two values.
o A real world data seldom has zero mean value, to solve this problem
oWe can introduce a none zero mean 𝜇 and this process is known as
demeaning.
o To do so, we first replace 𝑦𝑡 with 𝑦𝑡 − 𝜇

1
Time series Data Analysis: Stationary stochastic process

𝑦𝑡 − 𝜇 = 𝜌 𝑦𝑡−1 − 𝜇 + 𝑣𝑡
𝑦𝑡 = 𝜌𝑦𝑡−1 + 𝜇 − 𝜌𝜇 + 𝑣𝑡
If 𝛼 = 𝜇 1 − 𝜌 , → 𝜇 = 𝛼 1 − 𝜌which is the mean value of 𝑦𝑡
𝑦𝑡 = 𝛼 + 𝜌𝑦𝑡−1 + 𝑣𝑡
o we can accommodate a nonzero mean in 𝑦𝑡 by
 either working with the “demeaned” variable 𝑦𝑡 − 𝜇 or
 by introducing the intercept term in the autoregressive process 𝑦𝑡 .
o Corresponding to these two ways, we describe the “de-meaned”
variable (𝑦𝑡 − 𝜇 ) as being stationary around zero, or the variable 𝑦𝑡
as stationary around its mean value (𝜇 = 𝛼 1 − 𝜌)

1
Time series Data Analysis: Stationary stochastic process

o Example suppose 𝑦𝑡 = 0.7𝑦𝑡−1 + 𝑣𝑡 , and 𝜌 = 0.7 & 𝛼 = 1


o The figure shows the added influence of the constant term. The series now
fluctuates around a nonzero value 𝜇 = 1 1 − 0.7 = 3.33
1
Time series Data Analysis: Stationary stochastic process

o Another extension to our AR (1) model is to consider it fluctuating around


a linear trend (𝜇 + 𝛿𝑡)
o In this case we let the demeaned series behave like an autoregressive
model:
𝑦𝑡 − 𝜇 − 𝛿𝑡 = 𝜌[ 𝑦𝑡−1 − 𝜇 − 𝛿(𝑡 − 1 ] + 𝑣𝑡
Which can be rearranged as
𝑦𝑡 = α + 𝜌𝑦𝑡−1 + λ𝑡 + 𝑣𝑡 , 𝜌 <1
Now α = [𝜇 1 − 𝜌 + 𝜌𝛿) and 𝜆 = 𝛿(1 − 𝜌)
o This is example of trend stationary process, the detrended series is
stationary; 𝑦𝑡 is stationary around the deterministic trend line 𝜇 + 𝛿𝑡.

1
Time series Data Analysis: Stationary stochastic process

Example suppose 𝑦𝑡 = 0.7𝑦𝑡−1 + 𝑣𝑡 , and 𝜌 = 0.7 , 𝛼 = 1 & 𝜆 = .01


o The detrended series has a constant variance, and covariance that depend only
on the time separating observations, not the time at which they are observed.
1
Time series Data Analysis: NonStationarity

o The precise problem created by nonstationarity and the solution


to the problem depends on the nature of the nonstationarity .
o The most important types of nonstationarity in economic TS data
are trend and break nonstationarity.
o In this class we focus on trend nonstationarity.
o A trend is a persistent long-term movement of a variable
overtime. A TS variable fluctuating around its trend may have:
o Deterministic trend (well behaving non-random 𝑡, 𝑡 2 , … . ) or
o Stochastic trend (random and varies overtime)
In starting Example GDP has a definite trend (deterministic) and INF has a
stochastic trend.
1
Time series Data Analysis: Deterministic trend

o The simplest model for a deterministic trend for a variable 𝑦 is the


linear trend model
𝑦𝑡 = 𝑐1 + 𝑐2 𝑡 + 𝑢𝑡 , 𝑡 = 1,2, . . , 𝑇
o Another popular trend is one where, on average, a variable is
growing at a constant percentage rate.
ln(𝑦𝑡 ) = 𝑐1 + 𝑐2 𝑡 + 𝑢𝑡 , 𝑡 = 1,2, . . , 𝑇
o In this case the deterministic trend for 𝑦𝑡 is exp(𝑐1 + 𝑐2 𝑡), and 𝑦𝑡
will be trend stationary if 𝑢𝑡 is stationary.
o we could have also quadratic or Quebec trends
𝑄𝑢𝑎𝑑𝑟𝑎𝑡𝑖𝑐 𝑌𝑡 = 𝛼1 + 𝛼2 𝑡 2 + 𝑢𝑡 𝑡 = 1,2, . . , 𝑇

1
Time series Data Analysis: Stochastic trend

o In economics it is more appropriate to model economic TS as


having stochastic rather than deterministic trend. Why?
o because it is hard to reconcile the predictability implied by a
deterministic trend.
o In stochastic trend it would be easy to predict why the TS inc or dec.
Some examples of stochastic trend (Random walk model):
o If we rewrite our 𝐴𝑅(1) model as
𝑦𝑡 = 𝑦𝑡−1 + 𝑣𝑡 , 𝜌=1
And 𝑣𝑡 is white noise.
o The value of the series tomorrow is its value today plus unpredictable
change, because the path followed by 𝑦𝑡 consists of a random steps 𝑣𝑡 .

1
Time series Data Analysis: Stochastic trend

o Lets make some recursive substitution:


𝑦1 = 𝑦0 + 𝑣1
2
The stochastic
𝑦2 = 𝑦1 + 𝑣2 = 𝑦0 + 𝑣1 + 𝑣2 = 𝑦0 + 𝑣𝑠 trend (because it
𝑠=1 changes to
……………………….. unpredictable
𝑡 directions)

𝑦𝑡 = 𝑦𝑡−1 + 𝑣𝑡 = 𝑦0 + 𝑣𝑠
𝑠=1

Thus
𝐸(𝑦𝑡 ) = 𝑦0
𝑉𝑎𝑟(𝑦𝑡 ) = 𝑣𝑎𝑟 𝑣1 + 𝑣2 +. . +𝑣𝑡 = 𝐭𝝈𝟐
o A random walk has a mean equal to its initial value and variance that
increases overtime, eventually becoming infinity.

1
Time series Data Analysis: Stochastic trend

Random Walk with Drift


o Some series have an obvious upward or downward tendency.
o In such cases the best model for the TS must include an
adjustment for the tendency of the series.
o This adjustment leads to an extension of the random walk model
to include a drift term:
𝑦𝑡 = 𝛼 + 𝑦𝑡−1 + 𝑣𝑡
o Now each realization of the variable 𝑦𝑡 contains, an intercept plus the
last period value of 𝑦𝑡 and the error 𝑣𝑡 .

1
Time series Data Analysis: Stationary and Non-stationary TS

o Notice how the TS data appear to be “wandering” as well as “trending” upward (e).
o In general, random walk with drift models show definite trends either upward
(when the drift 𝛼 is positive) or downward (when the drift 𝛼 is negative).
1
Time series Data Analysis: Stochastic trend

o Again, we can get a better understanding of this behavior by


applying recursive substitution:
𝑦1 = 𝛼 + 𝑦0 + 𝑣1
2

𝑦2 = 𝛼 + 𝑦1 + 𝑣2 = 𝛼 + 𝑦0 + 𝑣1 + 𝑣2 = 2𝛼 + 𝑦0 + 𝑣𝑠
𝑠=1
………………………..
𝑡

𝑦𝑡 = 𝛼 + 𝑦𝑡−1 + 𝑣𝑡 = 𝑡𝛼 + 𝑦0 + 𝑣𝑠
𝑠=1
o The value of 𝑦 at time 𝑡 is made up of an initial value, the stochastic
trend component and a deterministic trend component 𝑡𝛼.
The variable 𝑦 wanders up and 𝐸 𝑦𝑡 = 𝑡𝛼 + 𝑦0
down as well as increases by a
fixed amount at each time 𝑡. 𝑣𝑎𝑟 𝑦𝑡 = 𝐭𝝈𝟐

1
Time series Data Analysis: Stochastic trend

o We can extend the random walk model even further by adding a


time trend:
𝑦𝑡 = 𝛼 + 𝜆𝑡 + 𝑦𝑡−1 + 𝑣𝑡
o the addition of a time-trend variable t strengthens the trend behavior.
𝑦1 = 𝛼 + 𝜆 + 𝑦0 + 𝑣1
2

𝑦2 = 𝛼 + 2𝜆 + 𝑦1 + 𝑣2 = 𝛼 + 2𝜆 + 𝑦0 + 𝑣1 + 𝑣2 = 2𝛼 + 3𝜆 + 𝑦0 + 𝑣𝑠
The additional
term has the
𝑠=1
effect of
……………………….. strengthening
𝑡 the trend
behavior
𝑦𝑡 = 𝛼 + 𝑡𝜆 + 𝑦𝑡−1 + 𝑣𝑡 = 𝑡𝛼 + [𝑡 𝑡 + 1 2]𝜆 + 𝑦0 + 𝑣𝑠
𝑠=1
o Where we have used the formula for a sum of an arithmetic progression,
1 + 2 + 3 + ⋯ + 𝑡 = [𝑡 𝑡 + 1 2]

1
Time series Data Analysis: Consequences of Stochastic Trends

o Estimating regressions involving variables with stochastic trends introduce


special problems:
o OLS estimates no longer have approximate normal distributions in
large samples. Hence, interval estimates and hypothesis tests will
no longer be valid.
o Precision of estimation would be lost and conclusions about relationships
between variables could be wrong.
o The t-statistics has a non-normal distribution even in large sample
size (very high significant t-statistic)
o One particular hazard is that two totally independent random walks can
appear to have a strong linear relationship when none exists.
o Outcomes of this nature have been given the name spurious
regressions.
1
Time series Data Analysis: Consequences of Stochastic Trends

Example suppose 𝑦𝑡 = 𝑦𝑡−1 + 𝑣𝑡 and 𝑥𝑡 = 𝑥𝑡−1 + 𝑢𝑡


o Suppose we regress 𝑦𝑡 on 𝑥𝑡 . Since 𝑦𝑡 and 𝑥𝑡 are uncorrelated nonstationary
processes, the 𝑅2 from the regression of y on 𝑥 should tend to zero;
o that is, there should not be any relationship between the two variables.

1
Time series Data Analysis: Consequences of Stochastic Trends

o As you can see, the coefficient of 𝑥 is highly statistically significant, and, although
the 𝑅2 value is low, it is statistically significantly different from zero.
o You may be tempted to conclude that there is a significant statistical
relationship between 𝑦 and 𝑥

1
Time series Data Analysis: Consequences of Stochastic Trends

o This is in a nutshell the phenomenon of spurious or nonsense regression.


oThe extremely low Durbin–Watson 𝑑 value suggests very strong first-order
autocorrelation.
o furthermore, an 𝑅2 > 𝑑 is a good rule of thumb to suspect that the estimated
regression is spurious
1
Time series Data Analysis: policy Importance

o There are also important policy considerations for distinguishing


between stationary and nonstationary variables.
o With nonstationary variables each error or shock 𝑣𝑡 has a lasting
effect, and these shocks accumulate.
o With stationary variables the effect of a shock eventually dies out
and the variable returns to its mean.
o Whether a change in a macroeconomic variable has a permanent or
transitory effect is essential information for policy makers.
o Thus our next steps would be answering the questions of:
 How can we test whether a series is stationary or nonstationary,
 and how do we conduct regression analysis with nonstationary data?

1
Time series Data Analysis: Unit Root Test

o There are many tests for assessing whether a series is stationary


or nonstationary. These includes:
 Graphical analysis, The correlogram test and
 Unit root tests (Dickey-Fuller test and Philips Person test …)
o The most popular one is the Dickey–Fuller (DF) test for a unit
root.
o Based up on the behavior of a given type of TS process, there are
three variations of the DF test, each one designed for a different
alternative hypothesis.

1
Time series Data Analysis: Unit Root Test

o The alternative hypothesis are

 that 𝑦𝑡 is stationary around a zero mean.

 that 𝑦𝑡 is stationary around a nonzero mean.

 that 𝑦𝑡 is stationary around a linear deterministic trend.

o The choice between these tests can be guided by the nature of


the data, revealed by plotting the series against time.
o If it is not obvious from a plot which test is the most relevant,
more than one test equation can be used to check the
robustness of a test conclusion.

1
Time series Data Analysis: DF Test (No constant, No trend)

o Consider the following AR (1) process


𝑦𝑡 = 𝜌𝑦𝑡−1 + 𝑣𝑡 , 𝑠𝑡𝑎𝑡𝑖𝑜𝑛𝑎𝑟𝑦 𝑤𝑕𝑒𝑛 𝜌 <1

𝑦𝑡 = 𝜌𝑦𝑡−1 + 𝑣𝑡 , 𝑁𝑜𝑛𝑠𝑡𝑎𝑡𝑖𝑜𝑛𝑎𝑟𝑦 𝑤𝑕𝑒𝑛 𝜌=1

o Here one way of testing for stationarity is to examine the value of


𝜌 i.e. test whether 𝜌 is equal to one or significantly less than one.

o Such kinds of tests are known as unit root test for stationarity.
o To make it formal consider
𝑦𝑡 = 𝜌𝑦𝑡−1 + 𝑣𝑡

Where 𝑣𝑡 is a white noise

1
Time series Data Analysis: DF Test (No constant, No trend)

o We can test for stationarity by using


𝐻0 : 𝜌 = 1
𝐻1 : 𝜌 < 1
Why is it a one till test?
o We can make it more convenient by subtracting 𝑦𝑡−1 from both sides
𝑦𝑡 − 𝑦𝑡−1 = 𝜌𝑦𝑡−1 − 𝑦𝑡−1 + 𝑣𝑡
∆𝑦𝑡 = (𝜌 − 1)𝑦𝑡−1 + 𝑣𝑡
∆𝒚𝒕 = 𝜸𝒚𝒕−𝟏 + 𝒗𝒕
Where 𝛾 = 𝜌 − 1 and ∆𝑦𝑡 = 𝑦𝑡 − 𝑦𝑡−1 , the hypothesis can be written as
𝐻0 : 𝜌 = 1 ↔ 𝐻0 : 𝛾 = 0
𝐻1 : 𝜌 < 1 ↔ 𝐻1 : 𝛾 < 0

1
Time series Data Analysis: DF Test (No constant, No trend)

The hypothesis can be written as


𝐻0 : 𝜌 = 1 ↔ 𝐻0 : 𝛾 = 0
𝐻1 : 𝜌 < 1 ↔ 𝐻1 : 𝛾 < 0
o The null hypothesis is that the series is nonstationary, in other words if
we don’t reject the null, then we conclude that it is a nonstationary
process.
o If we reject the null that 𝛾 = 0 then we conclude that the series is
stationary.

1
Time series Data Analysis: DF Test (with constant, No trend)

o Consider a time series 𝑦𝑡 that has no definite continuous trend, and


that is not obviously centered around zero.
o Suppose we wish to test whether this series is better represented by a
stationary 𝐴𝑅(1) or a nonstationary random walk.
o The nonstationary random walk is set up as the null hypothesis
𝐻0 : 𝑦𝑡 = 𝑦𝑡−1 + 𝑣𝑡
o the stationary AR(1) process becomes the alternative hypothesis
𝐻1 : 𝑦𝑡 = 𝛼 + 𝜌𝑦𝑡−1 + 𝑣𝑡 𝜌 <1
 Under 𝐻1 , the series fluctuates around a constant mean.
Under 𝐻0 , it wanders upward and downward but does not exhibit a clear
trend in either direction and does not tend to return to a constant mean.

1
Time series Data Analysis: DF Test (with constant, No trend)

o An obvious way to specify the null hypothesis in terms of the


parameters in the unrestricted: 𝐻0 : 𝛼 = 0, 𝜌 = 1
o But it has become more common to simply specify the null as
𝐻0 : 𝜌 = 1
o One way to justify omission of 𝛼 = 0 from 𝐻0 is recall 𝛼 = 𝜇(1 − 𝜌) if
𝜌 = 1 then 𝛼 = 0, therefore, testing for 𝐻0 : 𝜌 = 1 is sufficient.
o To make it more convenient, the test equation can be specified as,
∆𝒚𝒕 = 𝜶 + 𝜸𝒚𝒕−𝟏 + 𝒗𝒕
o Our 𝐻0 and 𝐻1 will not change (are the same as before).
 If we reject the 𝐻0 the TS is stationary around a none zero mean.

1
Time series Data Analysis: DF Test (with constant and trend)

o For a series that have a clear time trend, we need to modify test for
unit root.
o If we carry out a DF test on a trending but stationary series, we will
probability have a little power rejecting a unit root.
o Hence, it is necessary to control for time while making this test, not
to mistaken trend stationary process to difference stationary process.
o If 𝑦𝑡 is stationary around a linear trend and described by the process
𝑦𝑡 = 𝛼 + 𝜌𝑦𝑡−1 + 𝜆𝑡 + 𝑣𝑡 𝜌 <1
o If 𝑦𝑡 is random walk with drift, then it is described as
𝑦𝑡 = 𝛼 + 𝑦𝑡−1 + 𝑣𝑡

1
Time series Data Analysis: DF Test (with constant and trend)

o The DF test with intercept and trend is designed to discriminate


between these two models.
oThe latter became the null hypothesis and the former the alternative
hypothesis.
oIf the null hypothesis is rejected we conclude the series is trend
stationary.
o failure to reject the null hypotheses suggests 𝑦𝑡 is nonstationary, or
at least there is insufficient evidence to prove otherwise.
o The relevant equation for the test would be obtained by rewriting our
basic equation as:
∆𝒚𝒕 = 𝜶 + 𝜸𝒚𝒕−𝟏 + 𝝀𝒕 + 𝒗𝒕

1
Time series Data Analysis: DF Test (with constant and trend)

o The relevant null hypothesis would be


𝐻0 : 𝜌 = 1 ↔ 𝐻0 : 𝛾 = 0
𝐻1 : 𝜌 < 1 ↔ 𝐻1 : 𝛾 < 0
o in the null hypothesis λ = 0 is ignored, and it can be justified using the
same line of reasoning presented earlier.
𝑦𝑡 − 𝜇 − 𝛿𝑡 = 𝜌[𝑦𝑡−1 − 𝜇 − 𝛿 𝑡 − 1 ] + 𝑣𝑡
𝑦𝑡 − 𝜇 − 𝛿𝑡 = 𝜌𝑦𝑡−1 − 𝜌𝜇 − 𝜌𝛿𝑡 + 𝜌𝛿 + 𝑣𝑡
𝑦𝑡 = 𝜌𝑦𝑡−1 − 𝜌𝜇 − 𝜌𝛿𝑡 + 𝜌𝛿 − 𝜇 − 𝛿𝑡 + 𝑣𝑡
𝑦𝑡 = 𝜇 1 − 𝜌 + 𝜌𝛿 + 𝜌𝑦𝑡−1 + 𝛿𝑡(1 − 𝜌) + 𝑣𝑡
𝑦𝑡 = 𝛼 + 𝜌𝑦𝑡−1 + 𝜆𝑡 + 𝑣𝑡
Where 𝜇 + 𝛿𝑡 is the deterministic trend.
o With these definitions of 𝛼 and λ, setting 𝜌 = 1 implies 𝛼 = 𝛿 and 𝜆 = 0,
giving the random walk with drift.

1
Time series Data Analysis: DF Testing procedure

• Given the TS the appropriate DF model selected first by plotting the TS


of the original observations on the variable
o If the series is fluctuating around a sample average of zero, we use
the test equation one.
o If the series appears wondering around a sample average that is
non zero use test equation two.
o if the series appears wondering or fluctuating around a linear trend
use test equation three.
o To test the hypothesis in all the three cases, estimate the test equation
by least square and examine 𝜏 − 𝑠𝑎𝑡𝑖𝑠𝑡𝑖𝑐 for 𝐻0 : 𝛾 = 0.

1
Time series Data Analysis: DF Testing procedure

• Why 𝜏 − 𝑠𝑎𝑡𝑖𝑠𝑡𝑖𝑐 ?
• Unfortunately the 𝑡 − 𝑠𝑡𝑎𝑖𝑠𝑡𝑖𝑐𝑠 has no longer t-distribution (Asymptotic
SND even in large sample size] that we have used in may cases to test
a zero null for a regression coefficient. Why?
o Because when the 𝐻0 is true, 𝑦𝑡 is not stationary, the variance
increases as the sample size increases. And this increase will alter the
distribution of the usual 𝑡 − 𝑠𝑎𝑡𝑖𝑠𝑡𝑖𝑐𝑠.
o Recognizing this fact Dickey and Fuller developed an appropriate
critical values often called 𝜏 − 𝑠𝑎𝑡𝑖𝑠𝑡𝑖𝑐
oThe critical values in 𝜏 − 𝑠𝑎𝑡𝑖𝑠𝑡𝑖𝑐 depends on the type of equation we
are using.

1
Time series Data Analysis: Some examples of TS Models

• Recall that to carry out this one tail test of significance, we reject the null
hypothesis of stationarity if:
𝜏 ≤ 𝜏𝑐 𝑜𝑟 𝜏 > 𝜏𝑐
Don't reject if
𝜏 > 𝜏𝑐 𝑜𝑟 𝜏 < 𝜏𝑐
1
Time series Data Analysis: Some examples of TS Models

Example: to test for a unit root in three-month T-bill rate we estimated and
obtained the following result
𝑟3𝑡 = 0.625 − 0.091𝑟3𝑡−1
0.261 0.037
𝑛 = 123 𝑅2 = 0.048
A, can we carry out the usual t-test? B, what does the coefficient of 𝑟3𝑡−1
imply?
1
Time series Data Analysis: Some examples of TS Models

𝑟3𝑡 = 0.625 − 0.091𝑟3𝑡−1


0.261 0.037
𝑛 = 123 𝑅2 = 0.048
A, we cannot use the usual t-test to check for the hypothesis because
existence of nonstationarity may result a non STD which affects the
outcome of our test.
1
Time series Data Analysis: Some examples of TS Models

𝑟3𝑡 = 0.625 − 0.091𝑟3𝑡−1


0.261 0.037
𝑛 = 123 𝑅2 = 0.048
B, γ = −0.091 and 𝜌 = 1 + γ → 𝜌 = 1 − 0.091 = 0.909 , Thus the
𝜏 = 𝛾 𝑠𝑒 = − 0.091 0.037 = −2.46. At a 10% critical level,
𝜏 > 𝜏𝑐 −2.46 > −2.57 thus we fail to reject our 𝐻0

1
Time series Data Analysis: Some examples of TS Models

 Which model is inappropriate?


Model one is inappropriate because 𝜌 is positive and above one
 is LGDP stationary?
NO, show why?
1
Time series Data Analysis: Augmented DF Test

• It is an important extension of the DF test which allows for the


possibility that the error term is autocorrelation.
• Such autocorrelation is likely to occur if our earlier model does not have
the sufficient lag terms to capture full dynamic nature of the process.
• The representative equation is given as:

𝑝−1

∆𝑦𝑡 = 𝛼 + 𝜆𝑡 + 𝛾𝑦𝑡−1 + 𝑎𝑠 ∆𝑦𝑡−𝑠 + 𝑣𝑡


𝑠=1
o The inclusion of the lagged changes is intended to clean up any serial
correlation

1
Time series Data Analysis: Augmented DF Test

• While augmented Dickey–Fuller tests remain the most popular tests for
unit roots, the power of the tests is low in the sense that
• they often cannot distinguish between a highly persistent stationary
process (where 𝜌 is very close but not equal to 1) and a nonstationary
process (where 𝜌 = 1).
•The power of the test also diminishes as deterministic terms constant
and trend are included in the test equation.
• tests that have been developed with a view to improving the power of
the test: the Elliot, Rothenberg, and Stock (ERS), Phillips and Perron
(PP), Kwiatkowski, Phillips, Schmidt, and Shin (KPSS), and Ng and
Perron (NP) tests.

1
Time series Data Analysis: Augmented DF Test

• The ERS test proposes removing the constant/trend effects from the
data and performing the unit root test on the residuals.
• The distribution of the t-statistic is now devoid of deterministic terms
(i.e., the constant and/or trend).
• The PP test adopts a nonparametric approach that assumes a general
autoregressive moving-average structure and uses spectral methods to
estimate the standard error of the test correlation.
• Instead of specifying a null hypothesis of nonstationary, theKPSS test
specifies a null hypothesis that the series is stationary or trend
stationary. NP tests suggest various modifications of the PP and ERS
tests..

1
Time series Data Analysis: Some examples of TS Models

Steps in TS Analysis
1
Time series Data Analysis: REMOVING THE TREND

o There are important differences between a series with a trend and a


stationary series.
o Shocks to a stationary time series are necessarily temporary;
over time, the effects of the shocks will dissipate, and the series
will revert to its long-run mean level.
o On the other hand, a series containing a stochastic trend will not
revert to a long-run level.
o The components of the trend have important implications for the
appropriate transformation necessary to attain a stationary series.
o Whether we use detrending or Differencing

1
Time series Data Analysis: Trend Stationary Process

o The simplest model for a deterministic trend for a variable 𝑦 is the


linear trend model
𝑦𝑡 = 𝑐1 + 𝑐2 𝑡 + 𝑢𝑡 , 𝑡 = 1,2, . . , 𝑇
o If we assume any change in the error is zero (𝑢𝑡 − 𝑢𝑡−1 = 0), then
the coefficient 𝑐2 gives the ∆ 𝑦 from a one period to the next:
𝑦𝑡 − 𝑦𝑡−1 = 𝑐1 + 𝑐2 𝑡 − 𝑐1 + 𝑐2 𝑡 − 1 + ∆𝑢𝑡 = 𝑐2
 𝑡 does not necessarily have to start at “1” and increase in
increments of “1”.

1
Time series Data Analysis: Trend Stationary Variables

o The trend 𝑐1 + 𝑐2 𝑡 is called a deterministic trend because it does not


contain a stochastic (random) component.
o Since these fluctuations are given by changes in the error term,
𝑢𝑡 = 𝑦𝑡 − 𝑐1 + 𝑐2 𝑡
o 𝑦𝑡 is stationary if 𝑢𝑡 is stationary.
o When 𝑦𝑡 is trend stationary, we can use OLS to find estimates 𝑐1
and 𝑐2 and then convert 𝑦𝑡 to a stationary variable by removing the
trend:
𝑢𝑡 = 𝑦𝑡 − (𝑐1 + 𝑐2 𝑡)
 This process is known as detrending.

1
Time series Data Analysis: Trend Stationary Variables

o Furthermore, if we are considering a regression or an ARDL


model involving two trend stationary variables, say 𝑦𝑡 and 𝑥𝑡 , if
we estimate the model:
𝑦𝑡 = 𝛼1 + 𝛽𝑥𝑡 + 𝑒𝑡
o The result can suggest a significant relationship between the
variables even when none exists.
o Therefore to overcome the problem we must first remove their
trends, make them stationary, and then be able to estimate the
relationship.

1
Time series Data Analysis: Trend Stationary Variables

 This can be done by


1. making a separate regression for removing the trend term from
the two respective TS and regressing them: suppose 𝑦𝑡 = 𝑐1 +
𝑐2 𝑡 + 𝑢𝑡 and 𝑥𝑡 = 𝑏1 + 𝑏2 𝑡 + 𝑣𝑡 and furthermore, 𝑣𝑡 and 𝑢𝑡 are
stationary.
 Now to estimate the relationship between 𝑦𝑡 and 𝑥𝑡
o Frst we estimate the two TS using OLS 𝑦𝑡 = 𝑐1 + 𝑐2 and
𝑥𝑡 = 𝑏1 + 𝑏2 and then
o we remove their trends 𝑦𝑡 = 𝑦𝑡 -(𝑐1 + 𝑐2 ) and 𝑥𝑡 = 𝑥𝑡 -(𝑏1 + 𝑏2 ),
here 𝑦𝑡 and 𝑥𝑡 are just 𝑢𝑡 and 𝑣𝑡 respectively.

1
Time series Data Analysis: Trend Stationary Variables

o Finally assuming no lag effect we run 𝑦𝑡 = 𝛽𝑥𝑡 + 𝑒𝑡 , and the


regression result free from the curse of nonstationarity and
represents the effect of 𝑥 on 𝑦.
2. Or, we can just run the following regression:
𝑦𝑡 = 𝛼1 + 𝛼2 𝑡 + 𝛽𝑥𝑡 + 𝑒𝑡
o Both the first and the second procedures give as similar
outcome.
 In a more general from of ARDL
𝑝 𝑞

𝑦𝑡 = 𝜃𝑠 𝑦𝑡−𝑠 + 𝛽𝑠 𝑥𝑡−𝑟 + 𝑒𝑡
𝑠=1 𝑟=0
𝑝 𝑞

𝑦𝑡 = 𝛼1 + 𝛼2 𝑡 + 𝜃𝑠 𝑦𝑡−𝑠 + 𝛽𝑠 𝑥𝑡−𝑟 + 𝑒𝑡
𝑠=1 𝑟=0
1
Time series Data Analysis: Difference Stationary Process

 Now let consider the following random walk models


1. Assume a pure Random Walk (RW) model
𝑦𝑡 = 𝑦𝑡−1 + 𝑢𝑡
o What would happen if we rewrite the equation by subtracting 𝑦𝑡−1
from both sides:
𝑦𝑡 − 𝑦𝑡−1 = 𝑦𝑡−1 − 𝑦𝑡−1 + 𝑢𝑡
∆𝑦𝑡 = 𝑢𝑡
? Is it a stationary process?
Yes
o Thus the first difference of a RW TS are stationary, because by
assumption 𝑢𝑡 is purely random.
1
Time series Data Analysis: Difference Stationary Process

o Therefore we call such TS a Difference Stationary Process (DSP).


2. Now let assume RW with drift
𝑦𝑡 = 𝛼 + 𝑦𝑡−1 + 𝑢𝑡
o 𝑦𝑡 exhibits a positive or negative trend given the sig of 𝛼, and it is
also stochastic.
If we take its first difference we get,
∆𝑦𝑡 = 𝛼 + 𝑢𝑡
? Is this equation DSP
o Yes because we can eliminate the nonstationarity by taking the
first difference of 𝑦𝑡

1
Time series Data Analysis: Difference Stationary Process

3. Now let assume RW with drift and Deterministic Trend


𝑦𝑡 = 𝛼 + 𝜆𝑡 + 𝑦𝑡−1 + 𝑢𝑡
o If we take its first difference of the series we get,
∆𝑦𝑡 = 𝛼 + 𝜆𝑡 + 𝑢𝑡
o This is the same as deterministic trend, therefore differencing alone
will not transform our 𝑦𝑡 to stationary series.
o We need to remove the deterministic trend by applying
detrending.
o Hence, 𝑦𝑡 must be first differenced and then demeand to make it
stationary.

1
Time series Data Analysis: Integrated Stochastic Process

o Series like 𝑦𝑡 , which can be made stationary by taking their first


difference, are said to be integrated of order one, and denoted by
𝑦𝑡 ~𝐼(1).
o Stationary series are said to be integrated order zero, 𝐼(0).
o In general, the order of integration of a series is the minimum
number of times it must be differentiated to make it stationary.
 If a time series has to be differenced 𝑑 times to become
stationary; it is said to be integrated order of 𝑑 or 𝐼(𝑑).

1
Time series Data Analysis: properties of Integrated series

o Let 𝑦𝑡 , 𝑥𝑡 and 𝑧𝑡 be three time series


1. If 𝑥𝑡 ~𝐼 0 and 𝑦𝑡 ~𝐼 1 , then 𝑧𝑡 = 𝑦𝑡 + 𝑥𝑡 ~𝐼(1) that is, a linear
combination or the sum of stationary and non stationary TS is
nostationary.
2. If 𝑥𝑡 ~𝐼 𝑑 then 𝑧𝑡 = (𝑎 + 𝑏𝑥𝑡 ) ~𝐼(𝑑), where 𝑎 and 𝑏 are constant.
3. If 𝑥𝑡 ~𝐼 𝑑1 and 𝑦𝑡 ~𝐼 𝑑2 , then 𝑧𝑡 = (𝑎𝑥𝑡 + 𝑏𝑦𝑡 )~𝐼(𝑑2 ) , where
𝑑1 < 𝑑2 .
4. If 𝑥𝑡 ~𝐼 𝑑 and 𝑦𝑡 ~𝐼 𝑑 , then 𝑧𝑡 = (𝑎𝑥𝑡 + 𝑏𝑦𝑡 )~𝐼(𝑑 ∗ ), where 𝑑 ∗ is
generally equal to d, but in some cases 𝑑 ∗ < 𝑑, in this case we say
that there exists cointegration.

1
Time series Data Analysis: cointegration

o Suppose that we are interested in estimating the relationship


between two variables that are non stationary in their level, but both
are difference stationary 𝐼 1 .
o We expect their difference or any linear combination of them,
such as
𝜀𝑡 = 𝑦𝑡 − 𝛽1 − 𝛽2 𝑥𝑡
to be 𝐼 1 .
• However, there is an important case when 𝜀𝑡 = 𝑦𝑡 − 𝛽1 − 𝛽2 𝑥𝑡 is
stationary 𝐼 0 . In such cases 𝑦𝑡 and 𝑥𝑡 are said to be cointegrated.

1
Time series Data Analysis: cointegration

o Cointegration implies that 𝑦𝑡 and 𝑥𝑡 share similar stochastic trends


and, since the difference 𝜀𝑡 is stationary, they never diverge too far
from each other.
o Intuitively, if the two series are both 𝐼(1) , then this partial
difference between them might be stable around a fixed mean.
o The implication would be that the series are drifting together
at roughly the same rate (they have common stochastic
trend).
o For two series that satisfy this requirement the 𝛽 ′ 𝑠 (or any
multiple of it) are a cointegrating parameter.

1
Time series Data Analysis: cointegration

o In such a case, we can distinguish between:


o a long-run relationship between 𝑦𝑡 and 𝑥𝑡 , that is, the manner in
which the two variables drift upward together,
o and the short-run dynamics, that is, the relationship between
deviations of 𝑦𝑡 from its long-run trend and deviations of 𝑥𝑡 from
its long-run trend.

1
Time series Data Analysis: cointegration

Formal definition:
o Time series 𝑦𝑡 and 𝑥𝑡 are said to be cointegrated of order 𝑑, 𝑏
where 𝑑 ≥ 𝑏 ≥ 0, written as if
o If both series are integrated of order 𝑑,
o There exists a liner combination of these variables, say 𝛾𝑦𝑡 + 𝛿𝑥𝑡 ,
which is integrated of order 𝑑 − 𝑏 the vector [𝛾, 𝛿] is called the
cointegrating vector.
o It is also possible to generalize it for n variables case. If you want,
try it!

1
Time series Data Analysis: cointegration

Basic implication of the above definition:


o If we have two variables which are integrated of different orders, then
these two series cannot possibly be cointegrated. Why?
o It is, however, possible to have a mixture of different order series when
there are three or more series under consideration.
o In this case, a subset of the higher order series must be cointegrated to
the order of the lower series.
o For example, suppose 𝑌𝑡 ~𝐼 1 , 𝑋𝑡 ~𝐼 2 , and 𝑍𝑡 ~𝐼 2 .
o If 𝑋𝑡 and 𝑍𝑡 cointegrate then 𝑊𝑡 = 𝛼1 𝑋𝑡 + 𝛼2 𝑍𝑡 , will be 𝐼(1).

1
Time series Data Analysis: cointegration

o 𝑊𝑡 is now a potential candidate to cointegrate with the remaining


I(1) series 𝑌𝑡 .
o If so, then 𝑆𝑡 = 𝜑1 𝑌𝑡 + 𝜑2 𝑊𝑡 will be𝐼(1).
o We could summaries this set of Circumstances as
i. 𝑋𝑡 , 𝑍𝑡 ~𝐶𝐼 2,1 ;
ii. 𝑊𝑡 , 𝑌𝑡 ~𝐶𝐼(1,1) and hence
iii. 𝑆𝑡 ~𝐼 0 .
How can we tell two series are cointegrated?
o There are three basic ways of identifying the existence of
cointegration between two series.

1
Time series Data Analysis: cointegration

o The first one involves your expert knowledge and economic


theories about the relationship between the variables
o In the second one graph the series and see whether they appear
to have a common stochastic trend.
o In the third one we perform statistical test for cointegration. There
are two basic approaches (methods) of statistical test for
cointegration:
o a single equation cointegration technique
o and multivariate cointegration technique

1
Time series Data Analysis: cointegration

o Single-equation tests. Most single-equation tests for cointegration


are based on testing for unit roots in the cointegration regression
residuals.
o Finding a unit root means no cointegration.
o Because these residuals have been produced by a process that
makes them as small as possible, the popular DF and ADF tests
for unit roots are biased toward finding cointegration.
o The multivariate equation technique is Vector autoregression tests
which involves Johansson approach.

1
Time series Data Analysis: Engle Granger augmented approach (EG-AD test)

o Consider the following model:


𝑦𝑡 = 𝛽1 + 𝛽2 𝑥𝑡 + 𝜀𝑡
Where 𝑦𝑡 and 𝑥𝑡 are I(1).
o The Engle-Granger two step procedure would entail the following
steps
o First estimate the regression model above and obtain the
residuals: 𝑒𝑡 = 𝑦𝑡 − 𝛽1 − 𝛽2 𝑥𝑡
o Then use DF or ADF to test whether the estimated residual is
stationary or not: ∆𝑒𝑡 = 𝛾𝑒𝑡−1 + 𝑣𝑡
o Or We can add lags of ∆𝑒𝑡 . to account for serial correlation.

1
Time series Data Analysis: Engle Granger augmented approach (EG-AD test)

o Decision Rule: If the estimated residual is stationary say our


interest variables are cointegrated.
o Selecting the critical values depends on the type of model:
𝑒𝑡 = 𝑦𝑡 − 𝛽2 𝑥𝑡 … … … … … 𝑒𝑞1
𝑒𝑡 = 𝑦𝑡 − 𝛽1 − 𝛽2 𝑥𝑡 … … … 𝑒𝑞2
𝑒𝑡 = 𝑦𝑡 − 𝛽1 − 𝛿𝑡 − 𝛽2 𝑥𝑡 … 𝑒𝑞3
o The null and alternative hypotheses in the test for cointegration are
𝐻0 ∶ 𝑡ℎ𝑒 𝑠𝑒𝑟𝑖𝑒𝑠 𝑎𝑟𝑒 𝑛𝑜𝑡 𝑐𝑜𝑖𝑛𝑡𝑒𝑔𝑟𝑎𝑡𝑒𝑑
⇐⇒ 𝑟𝑒𝑠𝑖𝑑𝑢𝑎𝑙𝑠 𝑎𝑟𝑒 𝑛𝑜𝑛𝑠𝑡𝑎𝑡𝑖𝑜𝑛𝑎𝑟𝑦
𝐻1 ∶ 𝑡ℎ𝑒 𝑠𝑒𝑟𝑖𝑒𝑠 𝑎𝑟𝑒 𝑐𝑜𝑖𝑛𝑡𝑒𝑔𝑟𝑎𝑡𝑒𝑑
⇐⇒ 𝑟𝑒𝑠𝑖𝑑𝑢𝑎𝑙𝑠 𝑎𝑟𝑒 𝑠𝑡𝑎𝑡𝑖𝑜𝑛𝑎𝑟𝑦

1
Time series Data Analysis: Some examples of TS Models

𝐵𝑡 = 1.14 + 0.914𝐹𝑡
… … … … . (1)
𝑡 (6.548) (29.425)

𝑒𝑡 = 𝐵𝑡 − 1.14 − 0.914𝑥𝑡 … … (2)

 Let test whether 𝑦𝑡 = 𝐵𝑡 and 𝑥𝑡 = 𝐹𝑡 are cointegrated or not! Where 𝐵𝑡 is


bond rate and 𝐹𝑡 is federal fund rate.
 The estimated OLS regression between these variables and the
estimated residuals are given above.
1
Time series Data Analysis: Some examples of TS Models

∆𝑒𝑡 = −0.225𝑒𝑡−1 + 0.254∆𝑒𝑡−1


𝜏 (−4.196)

 At the 5% level of significance the critical value is -3.37. since 𝜏 < 𝜏𝑐 ,


thus, we reject the null hypothesis of unit root.
This implies that the bond rate and the federal funds rate are
cointegrated.
 In other words, there is a fundamental relationship between these two
variables (the estimated regression relationship between them is valid and
not spurious)
1
Time series Data Analysis: Engle Granger augmented approach (EG-AD test)

There are a number of critical limitations to this technique;


o one important limitation is inferences cannot be drawn using
standard t-statistics about the significance of the parameters of
the static long-run model, since the distribution of the estimators
of the cointegrating vector is generally no normal.
o Perhaps the most severe limitation is the possibility of more
than one cointegrating vector present in the data when the
cointegration regression contains more than two variables.
o So we need more advanced tests for cointegration which you learn
in advanced study

1
Time series Data Analysis: Error Correction Model

o We discussed the concept of cointegration as the relationship


between 𝐼(1) variables such that the residuals are 𝐼(0).
 A relationship between 𝐼(1) variables is also often referred to as
a long run relationship while:
 a relationship between 𝐼(0) variables is often referred to as a
short run relationship.
o We describe a dynamic relationship between 𝐼(0) variables, which
embeds a cointegrating relationship, known as the short-run error
correction model.

1
Time series Data Analysis: Error Correction Model

o Deriving the error correction model requires a bit of algebra.


o Let us start with a general model that contains lags of 𝑦 and 𝑥,
namely the 𝐴𝑅𝐷𝐿 (1, 1) model, where the variables are non-
stationary:
𝑦𝑡 = 𝛿 + 𝜃1 𝑦𝑡−1 + 𝛿0 𝑥𝑡 + 𝛿1 𝑥𝑡−1 + 𝑣𝑡
o Now recognize that if 𝑦 and 𝑥 are cointegrated, it means that
there is a long run relationship between them.
o To derive this exact relationship, we set
𝑦𝑡 = 𝑦𝑡−1 , 𝑥𝑡 = 𝑥𝑡−1 and 𝑣𝑡 = 0

1
Time series Data Analysis: Error Correction Model

o and then, imposing this concept in the 𝐴𝑅𝐷𝐿, we obtain:


𝑦 1 − 𝜃1 = 𝛿 + (𝛿0 + 𝛿1 )𝑥
o This equation can be rewritten as:
𝑦 = 𝛽1 + 𝛽2 𝑥
where 𝛽1 = 𝛿 (1 − 𝜃1 ) and 𝛽2 = (𝛿0 + 𝛿1 ) (1 − 𝜃1 )
o To repeat, we have now derived the implied cointegrating relationship
between 𝑦 and 𝑥; alternatively, we have derived the long-run relationship
that holds between the two 𝐼(1) variables.
o We will now manipulate the 𝐴𝑅𝐷𝐿 to see how it embeds the
cointegrating relation.

1
Time series Data Analysis: Error Correction Model

o First, add the term, −𝑦𝑡−1 , to both sides of the equation, this equation
can be rewritten as:
𝑦𝑡 − 𝑦𝑡−1 = 𝛿 + (1 − 𝜃1 )𝑦𝑡−1 + 𝛿0 𝑥𝑡 + 𝛿1 𝑥𝑡−1 + 𝑣𝑡
o Second, add the term 𝛿0 𝑥𝑡−1 − 𝛿0 𝑥𝑡−1 to the RHS to obtain:
𝑦𝑡 − 𝑦𝑡−1 = 𝛿 + (1 − 𝜃1 )𝑦𝑡−1 + 𝛿0 (𝑥𝑡 − 𝑥𝑡−1 ) + (𝛿0 + 𝛿1 )𝑥𝑡−1 + 𝑣𝑡
o Knowing ∆𝑦𝑡 = 𝑦𝑡 − 𝑦𝑡−1 and ∆𝑥𝑡 = 𝑥𝑡 − 𝑥𝑡−1 we can have:
∆𝑦𝑡 = 𝛿 + (𝜃1 −1)𝑦𝑡−1 + 𝛿0 ∆𝑥𝑡 + (𝛿0 + 𝛿1 )𝑥𝑡−1 + 𝑣𝑡
o If we then manipulate the equation to look like:

𝛿 𝛿0 + 𝛿1
∆𝑦𝑡 = (𝜃1 −1) + 𝑦𝑡−1 + 𝑥 + 𝛿0 ∆𝑥𝑡 + 𝑣𝑡
(𝜃1 −1) (𝜃1 −1) 𝑡−1

1
Time series Data Analysis: Error Correction Model

o Do a bit more tidying, using the definitions 𝛽1 and 𝛽2 , we get


∆𝑦𝑡 = −𝛼 𝑦𝑡−1 − 𝛽1 − 𝛽2 𝑥𝑡−1 + 𝛿0 ∆𝑥𝑡 + 𝑣𝑡
Where 𝛼 = (1 − 𝜃1 )
o As you can see, the expression in parenthesis is the cointegrating
relationship.
o In other words, we have embedded the cointegrating relationship
between 𝑦𝑡 and 𝑥𝑡 in a general ARDL framework.
o The last equation is called an error correction equation because:
A. The expression 𝑦𝑡−1 − 𝛽1 − 𝛽2 𝑥𝑡−1 shows the deviation of 𝑦𝑡−1
from its long run value, 𝛽1 + 𝛽2 𝑥𝑡−1 , in other words, the errors in the
previous period and

1
Time series Data Analysis: Error Correction Model

B. The term (𝜃1 −1) shows the „„correction‟‟ of ∆𝑦𝑡 to the „„error.‟‟
More specifically,
o If the error in the previous period is positive so that:
 𝑦𝑡−1 > (𝛽1 + 𝛽2 𝑥𝑡−1 ), then 𝑦𝑡 should fall and ∆𝑦𝑡 should be
negative.
o Conversely, if the error in the previous period is negative so that:
 𝑦𝑡−1 < (𝛽1 + 𝛽2 𝑥𝑡−1 ), then 𝑦𝑡 should rise and ∆𝑦𝑡 should be
positive.

1
Time series Data Analysis: Error Correction Model

o This means that if a cointegrating relationship between 𝑦 and 𝑥


exists, so that adjustments always work to „„error-correct,‟‟
o Then empirically we should also find that 1 − 𝜃1 > 0 which
implies that 𝜃1 < 1.
o If there is no evidence of cointegration between the variables,
then the term 𝜃1 would be insignificant.

1
Time series Data Analysis: Some examples of TS Models

∆𝐵𝑡 = −0.142 𝐵𝑡−1 − 1.429 − 0.77𝐹𝑡−1 + 0.84∆𝐹𝑡 − 0.327∆𝐹𝑡−1


𝑡 2.857 9.387 (3.885)

 Example: To illustrate, consider our earlier example of the bond and


federal funds rates. The result from estimating ECM using nonlinear
least squares is given above.

1
Time series Data Analysis: Some examples of TS Models

∆𝐵𝑡 = −0.142 𝐵𝑡−1 − 1.429 − 0.77𝐹𝑡−1 + 0.84∆𝐹𝑡 − 0.327∆𝐹𝑡−1


𝑡 2.857 9.387 (3.885)

 Note first that we need two lags (∆𝐹𝑡 ∆𝐹𝑡−1 ) to ensure that the residuals are
purged of all serial correlation effects.
 Second, note that the estimate 𝜃1 = −0.142 + 1 = 0.858 is less than one,
as expected.
1
Time series Data Analysis: Some examples of TS Models

∆𝐵𝑡 = −0.142 𝐵𝑡−1 − 1.429 − 0.77𝐹𝑡−1 + 0.84∆𝐹𝑡 − 0.327∆𝐹𝑡−1


𝑡 2.857 9.387 (3.885)

Interpretation: The error correction coefficient is negative and very significant.


For example, if the bond rate is above that federal fund rate by one point, bond
rate falls by .142 points on average in the next quarter.

1
Time series Data Analysis: Error Correction Model

Note: in the ECM the error correction expiration is replaced by lagged


residual as
𝑒𝑡−1 = 𝑦𝑡−1 − 𝛽1 − 𝛽2 𝑥𝑡−1
to make it easy for estimation.
o Thus, our ECM generally become
∆𝑦𝑡 = 𝛼0 + 𝛿0 ∆𝑥𝑡 + 𝛼𝑒𝑡−1 + +𝑣𝑡
o Now the ECM equation states that ∆𝑦 depends on ∆𝑥𝑡 and also the
equilibrium error term.
o If the latter is nonzero, then the model is out of equilibrium.

1
Time series Data Analysis: Some examples of TS Models

Steps in TS Analysis
1
END of slide

You might also like