STAT 3008 Applied Regression Analysis Tutorial 2 - Term 2, 2019 20
STAT 3008 Applied Regression Analysis Tutorial 2 - Term 2, 2019 20
ZHAN Zebang
19 February 2020
Example 1. (Alternative form of SLR) For a data set with observations {(xi , yi ), i = 1, ..., n},
iid
consider the regression model yi = α0 +α1 (xi − x̄)+ei , where ei ∼ N (0, σ 2 ). Find the maximum
likelihood estimates of α0 , α1 and σ 2 .
Example 2. (MLE method) For a data set with observations {(xi , yi ), i = 1, ..., n}, consider
iid
the regression model yi = β1 x2i + ei , where ei ∼ N (0, σ 2 ). Find the maximum likelihood esti-
mates of β1 and σ 2 .
1
2 Expectations and Variances
Recall: If X and Y are two random variables, a and b are two constants, then
• Var(aX + b) = a2 Var(X).
• Cov(aX, bY ) = ab Cov(X, Y ).
If X ∈ Rp and Y ∈ Rq are random vectors, Am×p and Bn×q are constant matrices, then
• E(AX) = A E(X).
• Cov(AX, BY ) = A Cov(X, Y )B 0 .
Example 4. (2016S Midterm) For the multiple regression model Y = Xβ +e, e ∼ N (0, σ 2 In ),
let β̂ = (X 0 X + kI)−1 X 0 Y where k is a constant. What are E(β̂) and Var(β̂)?
It is very useful and important later to define the hat matrix by H = X(X 0 X)−1 X 0 .
If X ∈ Rn×(p+1) and (X 0 X)−1 exists, then H ∈ Rn×n . Then, we can verify that
• H is symmetric: H 0 = H. ⇒ In − H is symmetric.
• HX = X, X 0 H = X 0 .
(1) E(ê) = 0.
(4) Cov(ê, Ŷ ) = O.