Sei sulla pagina 1di 54

Autocorrelation

Dr. Prabir K. Das


Indian Institute of Foreign Trade
Learning Objectives
• What is the nature of autocorrelation?
• What are the theoretical and practical
consequences of autocorrelation?
• Since the assumption of no autocorrelation
relates to the unobservable disturbances
ut, how does one know that there is
autocorrelation in any given situation?
• How does one remedy the problem of
autocorrelation?
Background
• Cross sectional data
• Time series data
• Combination of cross sectional and time
series (also known as pooled data or
panel data)
• Violation of assumptions of Gauss-Markov
theory
Background…(Cont’d.)
• Under both heteroscedasticity and
autocorrelation the usual OLS estimators,
although linear, unbiased, and
asymptotically (i.e., in large samples)
normally distributed, are no longer
minimum variance among all linear
unbiased estimators.
• These estimators are not efficient relative
to other linear and unbiased estimators.
Background
• These are not BLUE
• The t, F and chi-squared tests may not be
valid.
Autocorrelation and serial
correlation
• In a time series or panel data model, correlation
between the errors in different time periods is known
as auto correlation.
• It is also known as serial correlation.
• Autocorrelation - lag correlation between a given
series with itself, lagged by a number of time
units/epoch/frequency-commonly known as
displacement.
• Serial correlation – lag correlation between two
different series.
• It is tested using Durbin-Watson test statistic (for
lag 1 autocorrelation).
Autocorrelation

• The presence of autocorrelation in the


errors is a serious violation of the basic
regression assumption.
Why Does Autocorrelation
Occur?
• Failure to include one or more important
regressors in the model.
• Inertia or sluggishness – GNP, price
indexes, production, employment, and
unemployment exhibit (business) cycles.
• Specification bias:
Excluded variables case
 Incorrect functional form
Why Does Autocorrelation
Occur?...(Cont’d.)
• Cobweb phenomenon

Supplyt   1   2 Pt 1  ut

• Lags

Consumptiont  1   2incomet  3consumptiont 1  ut


Why Does Autocorrelation
Occur?...(Cont’d.)
• Manipulation of data – monthly to quarterly
• Data transformation

Yt   1   2 X t  u t
Level Form

Yt 1   1   2 X t 1  u t 1
First Difference Form

Yt   2 X t  ut
Consequences of Autocorrelation

• Ordinary least squares regression coefficients


are still unbiased. However, these are not
minimum variance i.e., these estimates are
inefficient.
• When the errors are positively autocorrelated,
the residual mean squares MSE may seriously
underestimate σ2.
• Consequently, the standard errors of the
regression coefficients may be too small.
Underestimating σ2 gives the analyst a false
impression of accuracy.
Consequences of
Autocorrelation…(Cont’d.)
• The confidence intervals and tests of
hypotheses based on the t and F
distributions are, strictly speaking, no
longer appropriate.
Consequences of
Autocorrelation…(Cont’d.)
• If autocorrelation is present because of an
omitted regressor, and if that regressor
can be identified and included in the
model, the apparent autocorrelation
should disappear.
• Using autocorrelation structure.
Testing Autocorrelation
• The test is based on the assumption that the
errors in the regression model are generated
by a first-order autoregressive process at
equally spaced time periods:

ut  ut 1  a t
Where ut is the error term in the model at time period t, at
is a NID(0,σ2 ) a random variable, and ρ(l ρl<1) is the
autocorrelation parameter (coefficient of first order
autocorrelation).
OLS Estimation in the presence of
First-Order Auto-regressive Process

yt     xt  ut
ut  ut 1  at
Where yt and xt are the observations on the
response and regressor variables at time
period t.
OLS Estimation in the presence of
First-Order Auto-regressive Process

• E(at)=0, var(at)=σa2, cov(at,at+s)=0 s≠0


• Rho is known as the coefficient of
autocorrelation.
It is also known as first-order coefficient
of autocorrelation, or more accurately
the coefficient of autocorrelation at lag 1.
OLS Estimation in the presence of
First-Order Auto-regressive Process
• at is known as white noise error term

ut  ut 1  at

• The above scheme is known as Markov first-


order autoregressive scheme, or simply a first-
order autoregressive scheme, usually denoted
as AR(1).
• Regression of ut on itself lagged one period.
Given the AR(1) scheme it can be
shown that

E (ut )  0
1
V (ut )   a (
2
)
1  2

s 1
cov(ut ut  s )    a2 ( )
1  2

cor (ut , ut  s )   s
That is, the errors have zero mean and constant
variance, but are autocorrelated unless ρ=0.
Detection of Autocorrelation

• Graphical Method
• Run Test (or Geary Test)
• Durbin-Watson Test
Run Test
• N=Total number of observations
• N1= No of (+) symbols
• N2=No of (–) symbols
• R=No of runs
• Under the null hypothesis that the
successive outcomes are independent,
and assuming N1>10 and N2>10, the
number of runs are normally distributed
with
Run Test…(Cont’d)

• Mean=E(R)=(2N1N2/N)+1
• Variance (σ2R )=[2N1N2(2N1N2-N)]/[(N)2(N-1)]
• Under null hypothesis
• Prob[E(R)-1.96σR≤ R ≤E(R)+ 1.96σR]=0.95
• Decision Rule: Reject H0 if the estimated R
lies outside this limit at 95% confidence
level, else do not reject.
Durbin-Watson Test
• Null hypothesis
H0: No positive autocorrelation (ρ=0)
H0*: No negative autocorrelation (ρ=0)
• H1: Presence of autocorrelation
• The test statistic is

 (u t  ut 1 ) 2
d t 2
n

 t
u 2

t 1
Durbin-Watson Test…(Cont’d.)
• d is approx. equal to 2(1 - ρ̂ ).
• Limits of d are 0 and 4.
• It depends on sample size and number of explanatory
variables.
• d lies between two bounds, say dL and dU, such that if d is
outside these limits a conclusion regarding the hypotheses can
be reached as presented under Decision Procedure.

d  d L , reject H 0
d L  d  dU , the test is inconclusive
4  dU  d  dU , donot reject H 0 or H 0* or both
4  dU to 4  d L : Zone of indecision
4  d L to 4 : Re ject H 0* ( Evidence of negative autocorrel ation)
Various Situations
+ive autocorrelation -ive autocorrelation
H1:ρ>0 H1:ρ<0
Reject ρ=0 Inconclusive Accept ρ=0 Inconclusive Reject ρ=0

0 dL dU 2 4-dU 4-dL 4

The DW test is invalid if some of the Xs are lags of


the dependent variable, that is, if they are of the
form Yt-1, Yt-2….
TESTS FOR AUTOCORRELATION

D-W test positive no negative


autocorrelation autocorrelation autocorrelation

0 2 4

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4

Thus d behaves as illustrated graphically above.

27
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dcrit 2 dcrit 4

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
To perform the Durbin–Watson test, we define critical values of d. The null hypothesis is H0:  = 0
(no autocorrelation). If d lies between these values, we do not reject the null hypothesis.

28
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dcrit 2 dcrit 4

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
The critical values, at any significance level, depend on the number of observations in the sample
and the number of explanatory variables.

29
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dcrit 2 dcrit 4

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
Unfortunately, they also depend on the actual data for the explanatory variables in the sample, and
thus vary from sample to sample.

30
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dcrit dU 2 dcrit 4

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
However Durbin and Watson determined upper and lower bounds, dU and dL, for the critical values,
and these are presented in standard tables.

31
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dcrit dU 2 dcrit 4

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
If d is less than dL, it must also be less than the critical value of d for positive autocorrelation, and
so we would reject the null hypothesis and conclude that there is positive autocorrelation.

32
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dcrit dU 2 dcrit 4

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
If d is above than dU, it must also be above the critical value of d, and so we would not reject the
null hypothesis. (Of course, if it were above 2, we should consider testing for negative
autocorrelation instead.)
33
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dcrit dU 2 dcrit 4

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
If d lies between dL and dU, we cannot tell whether it is above or below the critical value and so the
test is indeterminate.

34
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dU 2 4
1.43 1.62
(n = 45, k = 3, 5% level)

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
Here are dL and dU for 45 observations and two explanatory variables, at the 5% significance level.

35
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dU 2 4
1.43 1.62 2.38 2.57
(n = 45, k = 3, 5% level)

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
There are similar bounds for the critical value in the case of negative autocorrelation. They are not
given in the standard tables because negative autocorrelation is uncommon, but it is easy to
calculate them because are they are located symmetrically to the right of 2.
36
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dU 2 4
1.43 1.62 2.38 2.57
(n = 45, k = 3, 5% level)

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
So if d < 1.43, we reject the null hypothesis and conclude that there is positive autocorrelation.

37
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dU 2 4
1.43 1.62 2.38 2.57
(n = 45, k = 3, 5% level)

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
If 1.43 < d < 1.62, the test is indeterminate and we do not come to any conclusion.

38
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dU 2 4
1.43 1.62 2.38 2.57
(n = 45, k = 3, 5% level)

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
If 1.62 < d < 2.38, we do not reject the null hypothesis of no autocorrelation.

39
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dU 2 4
1.43 1.62 2.38 2.57
(n = 45, k = 3, 5% level)

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
If 2.38 < d < 2.57, we do not come to any conclusion.

40
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dU 2 4
1.43 1.62 2.38 2.57
(n = 45, k = 3, 5% level)

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
If d > 2.57, we conclude that there is significant negative autocorrelation.

41
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dU 2 4
1.24 1.42 2.58 2.76
(n = 45, k = 3, 1% level)

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
Here are the bounds for the critical values for the 1% test, again with 45 observations and two
explanatory variables.

42
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dU 2 4
1.24 1.42 2.58 2.76
(n = 45, k = 3, 1% level)

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
The Durbin-Watson test is valid only when all the explanatory variables are deterministic. This is in
practice a serious limitation since usually interactions and dynamics in a system of equations
cause Assumption C.7 part (2) to be violated.
43
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dU 2 4
1.24 1.42 2.58 2.76
(n = 45, k = 3, 1% level)

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
In particular, if the lagged dependent variable is used as a regressor, the statistic is biased towards
2 and therefore will tend to under-reject the null hypothesis. It is also restricted to testing for AR(1)
autocorrelation.
44
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dU 2 4
1.24 1.42 2.58 2.76
(n = 45, k = 3, 1% level)

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
Despite these shortcomings, it remains a popular test and some major applications produce the d
statistic automatically as part of the standard regression output.

45
TESTS FOR AUTOCORRELATION

Durbin–Watson test

positive no negative
autocorrelation autocorrelation autocorrelation

0 dL dU 2 4
1.24 1.42 2.58 2.76
(n = 45, k = 3, 1% level)

In large samples d  2  2
No autocorrelation d 2
Severe positive autocorrelation d 0
Severe negative autocorrelation d 4
It does have the appeal of the test statistic being part of standard regression output. Further, it is
appropriate for finite samples, subject to the zone of indeterminacy and the deterministic regressor
requirement.
46
Critical Values of Durbin-Watson Statistic
Strategies When DW Test is Significant
Limitations of D-W Test
• Lagged dependent variable in the model
• Exogenous variable in the model
Durbin h Test
Higher Order Autocorrelation

Yt  1   2 X t 2   3 X t 3  ...   k X k  ut
ut  1ut 1   2ut  2   3ut 3  ...   p ut  p  vt

Ho:ρ1=ρ2=ρ3=…=ρp=0
H1: at least one of them is non-zero
Test Statistic
• The Breusch-Godfrey Lagrange Multiplier
Test
Remedial Measures
• Try a different functional form
• Add variable(s)
• Delete variable(s)
• Increase the interval between
observations (daily to weekly; weekly to
monthly etc.)
Thank You

Potrebbero piacerti anche