[R] extend summary.lm for hccm?
Dirk Eddelbuettel
edd at debian.org
Sun Dec 24 05:16:04 CET 2006
On 23 December 2006 at 20:46, ivo welch wrote:
| I wonder whether it is possible to extend the summary method for the
| lm function, so that it uses an option "hccm" (well, model "hc0"). In
| my line of work, it is pretty much required in reporting of almost all
| linear regressions these days, which means that it would be very nice
| not to have to manually library car, then sqrt the diagonal, and
| recompute T-stats; instead, I would love to get everything in the same
| format as the current output---except errors heteroskedasticity
| adjusted.
|
| easy or hard?
Did you consider the 'sandwich' package? A simple
> install.packages("sandwich")
> library(sandwich)
> ?vcovHC
> ?vcovHAC
should get you there.
Dirk
--
Hell, there are no rules here - we're trying to accomplish something.
-- Thomas A. Edison
More information about the R-help
mailing list