View source: R/mc_robust_std.R
| mc_robust_std | R Documentation |
Computes cluster-robust (sandwich-type) standard errors for the
regression parameters of an object of class mcglm, accounting
for within-cluster correlation.
mc_robust_std(object, id)
object |
An object of class |
id |
An integer or factor vector identifying clusters or subjects. Its length and ordering must match the number and ordering of the observations used to fit the model. |
The robust variance–covariance matrix is obtained using an empirical estimator based on clustered residuals and the sensitivity matrix of the estimating equations. The implementation assumes that the data are correctly ordered such that observations belonging to the same cluster are stored in contiguous rows.
A list with two components:
A numeric vector containing the robust standard errors of the regression parameter estimates.
A numeric matrix giving the robust variance–covariance matrix of the regression parameter estimates.
The returned objects are computed under the assumption that the data are in the correct cluster order.
Wagner Hugo Bonat, wbonat@ufpr.br
Nuamah, I. F., Qu, Y., and Aminu, S. B. (1996). A SAS macro for stepwise correlated binary regression. Computer Methods and Programs in Biomedicine, 49, 199–210.
mc_bias_correct_std
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.