1
$\begingroup$

Prove that $\sum \hat y_i(y_i-\hat y_i)=0$ for linear regression model.

Attempt

We have that $\sum \hat y_i(y_i-\hat y_i)=\sum x_i\hat\beta(x_i\beta-x_i\hat\beta)=(X\hat\beta)'(X\beta)-(X\hat\beta)'(X\hat\beta)=\hat\beta'X'X\beta-\hat\beta'X'X\hat\beta= \ ?$

Could someone please help?

$\endgroup$
3
  • $\begingroup$ Plug in $\hat \beta = (X'X)^{-1}X'Y$ to see if you can get the result. $\endgroup$
    – user158565
    Oct 27, 2018 at 23:32
  • $\begingroup$ Hint: look at the first order conditions that define $\hat{\beta}$ $\endgroup$ Oct 27, 2018 at 23:32
  • $\begingroup$ Additionally your second eq is wrong $\endgroup$ Oct 27, 2018 at 23:34

1 Answer 1

0
$\begingroup$

$\sum \hat y_i(y_i-\hat y_i)=\sum x_i\hat\beta(y_i-x_i\hat\beta)=(X\hat\beta)'Y-(X\hat\beta)'(X\hat\beta)=\hat\beta'X'Y-\hat\beta'X'X\hat\beta= \hat\beta'X'Y-\hat\beta'X'X(X'X)^{-1}X'Y = \hat\beta'X'Y - \hat\beta'X'Y = 0$

$\endgroup$
2
  • $\begingroup$ what do you mean? need more characters? $\endgroup$ Oct 28, 2018 at 0:26
  • $\begingroup$ "at least 15 characters" to click "Add Comment" $\endgroup$
    – user158565
    Oct 28, 2018 at 0:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.