# homoskedastic and heteroskedastic standard errors

Stock and Watson is absolutely not clear in this respect, at least as far as their derivation.

It says that, starting from the variance of $\hat{\beta_{1}}$ (that is $=\frac{1}{n}\times \frac{var[(X_i-\mu _{X})u_i]}{(\sigma_{X}^{2})^2}=\frac{\sigma_{v}^{2}}{n(\sigma_{X}^{2})^2}$), we have to replace the unobservable values of $\sigma_{X}^{2}$ and $\sigma_{v}^{2}$ with estimators constructed on the basis of the data of sample, in this way:

$\hat{var}(\hat{\beta_1})=\frac{1}{n}\times \frac{\frac{1}{n-2}\sum_{i=1}^{n}\hat{v}_{i}^{2}}{[\frac{1}{n}\sum_{i=1}^{n}(X_i-\bar{X})^2]^2} =\frac{1}{n}\times \frac{\frac{1}{n-2}\sum_{i=1}^{n}(X_i-\bar{X})^2{e_{i}}^{2}}{[\frac{1}{n}\sum_{i=1}^{n}(X_i-\bar{X})^2]^2}$

So results that $SE(\hat{\beta_1})=\sqrt{\hat{var}(\hat{\beta_1})}$, but it does not clearly specify whether this formula is for robust heteroskedasticity or not. And in the event that it is, it does not even explain how to derivate the robust heteroskedasticity standard error for $\hat{\beta_0}$.

Then it says that homoskedaticity standard error for $\hat{\beta_1}$ is $SE(\hat{\beta_1})=\sqrt{\frac{1}{n}\times \frac{\frac{1}{n-2}\sum_{i=1}^{n}{e_{i}}^{2}}{[\frac{1}{n}\sum_{i=1}^{n}(X_i-\bar{X})^2]^2}}$. Why does it delete $\sum_{i=1}^{n}(X_i-\bar{X})^2$? Maybe for $E(u_i|X_i)=0$?

What is more, it does not explain the homoskedastic standard error of $\hat{\beta_0}$ or its derivation.

Anyone could help me to clarify the formulas?

• The s.e.s are for the heteroskedastic case, as homoskedasticity has not been assumed. I do not see that the variation in $X$ would be deleted anywhere - you seem to have incorrectly copied their eq. (5.4), referring to the 2nd edition. I address the intercept in your other question. See also S&W's appendix 5.1. – Christoph Hanck Jan 4 '18 at 15:18
• @ChristophHanck The equation 5.4 4th edition is correct: $\frac{1}{n}\times \frac{\frac{1}{n-2}\sum_{i=1}^{n}(X_i-\bar{X})^2{e_{i}}^{2}}{[\frac{1}{n}\sum_{i=1}^{n}(X_i-\bar{X})^2]^2}$. I've only expressed $\hat{u_{i}^{2}}=e_{i}^{2}$. In every case i think that i will confine myself to answering that s.e.s. replace observed variances with their respective estimators. – Francesco Totti Jan 4 '18 at 15:52
• @ChristophHanck In appendix 5.1 pag. 136 there are homoskedasticity standard errors formulas (5.29 and 5.30). – Francesco Totti Jan 4 '18 at 15:54
• Yes, they, are, but why do you then delete $(X_i-\bar{X})^2$ in the above expression for $SE(\hat{\beta_1})$? – Christoph Hanck Jan 4 '18 at 16:19
• 5.29: $\hat\sigma_{\hat{\beta_1}}=\frac{{s_{\hat{u}}}^{2}}{\sum (X_i-\bar{X})^2}$ with ${s_{\hat{u}}}^{2}=\frac{1}{n-2}\sum {e_{i}}^{2}=\frac{RSS}{n-2}$ (4.19 pag. 95). So $\hat\sigma_{\hat{\beta_1}}=\frac{\frac{1}{n-2}\sum {e_{i}}^{2}}{\sum (X_i-\bar{X})^2}$. If you refer to above expression, $v_i\equiv (X_i-\bar{X})^2u_{i}$. – Francesco Totti Jan 4 '18 at 16:34