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$
  • $\begingroup$ Plug in $\hat \beta = (X'X)^{-1}X'Y$ to see if you can get the result. $\endgroup$ – user158565 Oct 27 '18 at 23:32
  • $\begingroup$ Hint: look at the first order conditions that define $\hat{\beta}$ $\endgroup$ – probabilityislogic Oct 27 '18 at 23:32
  • $\begingroup$ Additionally your second eq is wrong $\endgroup$ – probabilityislogic Oct 27 '18 at 23:34
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$
  • $\begingroup$ what do you mean? need more characters? $\endgroup$ – g.a.l.l.e.t.a Oct 28 '18 at 0:26
  • $\begingroup$ "at least 15 characters" to click "Add Comment" $\endgroup$ – user158565 Oct 28 '18 at 0:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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