Professional Documents
Culture Documents
MOOC Econometrics: Christiaan Heij
MOOC Econometrics: Christiaan Heij
MOOC Econometrics
Lecture 2.3 on Multiple Regression: Model: y = X β + ε
Estimation
Dimensions: y (n × 1), X (n × k): observed data
Christiaan Heij β (k × 1), ε (n × 1): unobserved
Objective:
→ Estimate β by (k × 1) vector b so that Xb is ‘close’ to y .
Test = y 0 y − y 0 Xb − b 0 X 0 y + b 0 X 0 Xb
Prove that #(parameters) = k ≤ n = #(observations). = y 0 y − 2b 0 X 0 y + b 0 X 0 Xb
X 0 Xa = 0 ⇒ a0 X 0 Xa = (Xa)0 Xa = 0 ⇒ Xa = 0 ⇒ a = 0.
Fitted values: ŷ = Xb = X (X 0 X )−1 X 0 y = Hy .
Last step follows from rank(X ) = k.
Residuals: e = y − Xb = y − Hy = My .
So: b = (X 0 X )−1 X 0 y
e and ŷ orthogonal: e 0 ŷ = (My )0 Hy = y 0 M 0 Hy = 0.
Lecture 2.3, Slide 5 of 10, Erasmus School of Economics Lecture 2.3, Slide 6 of 10, Erasmus School of Economics
σ 2 = E (ε2i )
Estimate unknown ε = y − X β by residuals e = y − Xb.
1 Pn
Sample variance of residuals: σ̂ 2 = n−1 i=1 (ei − e)2 .
Test
Check that the (n × 1) vector of residuals e satisfies k linear restrictions,
so that e has (n − k) ‘degrees of freedom’.
1 0 1 Pn
OLS estimator: s 2 = n−k e e = n−k
2
i=1 ei
The ‘X -plane’ is k-dimensional subspace spanned by columns of X ,
that is, set of vectors Xa with a arbitrary (k × 1) vector.
Unbiased under standard assumptions (see next lecture).
Lecture 2.3, Slide 7 of 10, Erasmus School of Economics Lecture 2.3, Slide 8 of 10, Erasmus School of Economics
R-squared (R 2 ) TRAINING EXERCISE 2.3
2
P
2 (yi −y )(ŷi −ŷ )
2
Definition: R = cor(y , ŷ ) = ,
(yi −y )2 (ŷi −ŷ )2
P P
Lecture 2.3, Slide 9 of 10, Erasmus School of Economics Lecture 2.3, Slide 10 of 10, Erasmus School of Economics