01.06.2015 Views

GLS (Generalized Least Squares) - Paul Johnson Homepage

GLS (Generalized Least Squares) - Paul Johnson Homepage

GLS (Generalized Least Squares) - Paul Johnson Homepage

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

⎡<br />

V ar(e) =<br />

⎢<br />

⎣<br />

In weighted least squares, we use estimates of σ 2 e i<br />

σe 2 ⎤<br />

1<br />

0 0 0<br />

0 σe 2 2<br />

0 0<br />

. .. 0<br />

.<br />

0<br />

..<br />

0 0 σe 2 ⎥<br />

N−1<br />

0 ⎦<br />

0 0 0 0 σe 2 N<br />

as weights.<br />

(6)<br />

S(ˆb) =<br />

N∑<br />

i=0<br />

1<br />

̂σ 2 e i<br />

(y i − ŷ i ) 2 =<br />

Consider the WLS problem. If the heteroskedastic case occurs<br />

N∑<br />

w i (y i − ŷ i ) 2 (7)<br />

i=0<br />

N∑<br />

N∑<br />

S(ˆb) = w i (y i − ŷ i ) 2 = ( √ w i y i − √ w i ŷ i ) 2 (8)<br />

i=1<br />

i=1<br />

= w 1 (y 1 − ŷ 1 ) 2 + w 2 (y 2 − ŷ 2 ) 2 + · · · + w N (y N − ŷ N ) 2 (9)<br />

3 <strong>Generalized</strong> <strong>Least</strong> <strong>Squares</strong> (<strong>GLS</strong>)<br />

Suppose, generally, the Variance/Covariance matrix of residuals is<br />

⎡<br />

σ1 2 Cov(e 1 , e 2 ) Cov(e 1 , e 2 ) · · · Cov(e 1 , e N )<br />

Cov(e 1 , e 2 ) σ2<br />

2 σ3<br />

2<br />

V =<br />

. .<br />

..<br />

⎢<br />

⎣<br />

σN−1 2 Cov(e 1 , e N−1 )<br />

Cov(e 1 , e N ) Cov(e 1 , e N−1 σN<br />

2<br />

⎤<br />

⎥<br />

⎦<br />

(10)<br />

You can factor out a constant σ 2 if you care to (MM&V do, p. 51).<br />

If all the off diagonal elements of V are set to 0, then this degenerates to a problem of heteroskedasticity,<br />

know as Weighted <strong>Least</strong> <strong>Squares</strong> (WLS).<br />

If the off diagonal elements of V are not 0, then there can be correlation across cases. In a<br />

time series problem, that amounts to “autocorrelation.” In a cross-sectional problem, it means<br />

that various observations are interrelated.<br />

The “sum of squared errors” approach uses this variance matrix to adjust the data so that the<br />

residuals are homoskedastic or that the cross-unit correlations are taken into account.<br />

Let<br />

W = V −1 (11)<br />

The idea behind WLS/<strong>GLS</strong> is that there is a way to transform y and X so that the residuals<br />

are homogeneous, some kind of weight is applied.<br />

2

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!