[R] Robust standard errors

Thomas Lumley tlumley at u.washington.edu
Mon Mar 24 16:19:37 CET 2003


On Mon, 24 Mar 2003, John Fox wrote:

> Dear Nirmala,
>
> The object of the various HCCM estimators is to compute standard errors
> that are approximately correct when the error variance in a linear model
> isn't constant. I don't see the relevance to a logit model. Perhaps you can
> explain further what you have in mind (or perhaps someone else is aware of
> a generalization to GLMs).

Exactly the same reasoning as for linear models leads to `sandwich'
standard error estimators for GLMs.  GLMs ordinarily require mean and
variance correctly specified to give valid standard errors; the sandwich
estimators require only that the mean is correctly specified.

For a binary logit model on independent observations this doesn't get you
much further, as the entire likelihood is going to be correct if the mean
is correct, but for other GLMs it is a useful technique.

Some options are to use the gee or geepack packages to do an analysis with
only one observation per group, or the survey package to do an analysis
without sampling weights.


	-thomas



More information about the R-help mailing list