2
$\begingroup$

For the sandwich package in R, when using vcovHC(model) where model <- lm(Y~X), what gives the effect estimate regarding the relationship between X and Y (for each unit change in X, Y will change ....)?

Is it still the estimate of the X coefficient given by summary(model)? Or is it now the covariance of the two model parameters given by vcovHC(model)? Or something else entirely?

$\endgroup$
2
$\begingroup$

When using the sandwich standard error, the association between $X$ and $Y$ is no different than in the model: the regression slope, or "X" coefficient is the same as is obtained by coef(model). What vcovHC does differently is calculate the standard errors for the confidence interval and the p-value of the model.

If you would like to see output similar to summary(model) but using sandwich errors, you can make use of the lmtest package and function parmtest by calling:

parmtest(model, .vcov=vcovHC)

and contrast these findings with the model based summary: summary(model).

$\endgroup$

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.