Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
183
184
Introduction
In a regression problem with time series data (where the variables have subscript "t" denoting the time the variable was observed), it is common for the error terms to be correlated across time, but with a constant variance; this is the problem of "autocorrelated disturbances," which will be considered in the next lecture. For regressions with cross-section data (where the subscript "i" now denotes a particular individual or firm at a point in time), it is usually safe to assume the errors are uncorrelated, but often their variances are not constant across individuals. This is known as the problem of heteroskedasticity (for "unequal scatter"); the usual assumption of constant error variance is referred to as homoskedasticity. Although the mean of the dependent variable might be a linear function of the regressors, the variance of the error terms might also depend on those same regressors, so that the observations might "fan out" in a scatter diagram, as illustrated in the following diagrams.
185
. . . . .
Y
. . . . .
. . . . .
X
Homoskedasticity
. . . . .
Y
. . . . .
. . . . .
X
Increasing heteroskedasticity
. . . . .
. . . . .
. . . . .
. . . . .
. . . . .
X
"U-shaped" heteroskedasticity
186
@ x i % gi % gi
yi ' j xij @
j'1
C C C
if i i )
2
Var(gi) '
2 i
'
@ hi , some hi
187
, etc.
However, we only observe some group averages: 1 s ys ' j yis , ns i'1 Then ys ' % @ x s % g s , with Var(g s) '
2 n
1 ns
@ hs .
188
2. Random Coefficients
Both the intercept and slope vary (randomly) across i, yi / "i % $i @ xi , where E( i) / V( i) /
2
, E( i) / Cov( i , i) / %
, Var( i) / , so that
, and yi /
@ x i % gi ,
with gi / ( i & ) % ( i & ) @ x i , which has E(gi) / 0 and V(gi) ' ' /
2 2
% 2 @ xi %
@ xi
2 2
@ (1 % 2 @ hi .
1 @ xi %
2 @ xi )
189
@ x i % gi , @ x i) 2 /
with
2
( %
@ hi ,
190
191
192
@ hi
where hi is known (e.g., grouped data), then yi ' Y yi hi yi ' etc. Since Var(gi ) '
( 2 (
% '
@ x i % gi , @ 1 hi
( (
Var(gi) ' @ xi hi
(
@ hi or
gi hi yi hi
@ zi %
@ xi % gi , with yi /
, zi /
1 hi
this transformed equation to get efficient estimates of " and $ . For multiple regression model, divide the dependent variable and all of the regressors (including the constant term) by hi , then do least squares.
193
j
i'1
( yi
& a @ zi & b @
(2 xi
' j
i'1
thus, a more efficient estimator is obtained by downweighting the squared residuals for observations with large variances, in proportion to those variances.
194
errors for coefficient estimates. C R2 must be redefined, since transformed model usually has no intercept term.
195
196
% % % %
' '
2 2
% zi1 % %
% ui , E(ui) ' 0 ,
where zi1,...,ziL are known functions of regressors (e.g., zi1 = xi , zi2 = xi2 for random coefficients model). Idea: replace unknown squared errors gi with squared residuals ei ' (yi & yi)2 from LS, then regress ei zi1,...,ziL . Steps: (1) (2) (3) Get LS residuals ei ' yi & & @ xi . Get R2 from regression of ei on 1, zi1,...,ziL . Construct usual F-statistic 1&R reject homoskedasticity if ) exceeds critical value from F-table with L-1 and n-L degrees of freedom.
2
Econometrics Laboratory C University of California at Berkeley C 22-26 March 1999
on 1,
)=
R2
n&L L&1
197
'
1zi1
% %
LziL
C Idea: Use squared residual regression to estimate weights. C Steps: (1) Fit
yi ' % @ xi % gi
2
on
2
1,z1i,...,z1L
get
(3)
Replace
minimize j
i'1
to estimate ",$ .
198
(exact WLS).
'
1x i
2 2x i
regress ei on 1, xi, xi2 , test H0: *1 = *2 = 0 with F-test. If H0 (homoskedasticity) rejected, let
2 2 i ' 2 % 1x i % 2x i ,
plug into WLS formula. (For multiple regression, set ziR equal to squares and cross-products of regressors.)
199
on 1 and zi1 ' ( i)2 ' ( % xi)2 , do F-test (or t-test) for y exclusion of
2
yi .
200
' s 2 / j (xi & x)2 ' s 2 j (xi & x)2 / j (xi & x)2 2 . Formula assumes
201
C Corrected Variance Estimator for : Now use V( ) ' j ei (xi & x)2 / j (xi & x)2 2 where ei ' yi & & xi . Note V( ) s 2 / (xi & x)2 unless ei ' s 2 '
2 2
1 2 j ei n&k
C Formula for Multiple Regression: Similar, but more complicated. Fortunately, many computer packages (e.g., TSP) compute "Eicker-White" standard errors as an option.