Learn R Programming

rqlm (version 4.5-1)

rqlm-methods: Extract Coefficients, Covariance Matrices, and Model Families

Description

Extract coefficient estimates, the full estimated robust covariance matrix, or the family of the underlying fitted working model.

Usage

# S3 method for rqlm
coef(object, ...)
# S3 method for rqlm
vcov(object, ...)
# S3 method for rqlm
family(object, ...)
# S3 method for ttemsm
coef(object, ...)
# S3 method for ttemsm
vcov(object, ...)
# S3 method for ttemsm
family(object, ...)

Value

For coef, a named numeric coefficient vector. For vcov, the estimated covariance matrix. For family, the family object of the underlying fitted model.

Arguments

object

An object returned by rqlm, qlogist, or ttemsm.

...

Additional arguments; currently unused.

Details

The qlogist function returns an object of class "rqlm" and uses the same methods. Coefficients and their covariance matrix remain on the model scale, even when eform = TRUE. The covariance matrix corresponds to the selected var.method.

For qlogist, family returns the binomial-logit family of the augmented-data working model. Its coefficients parameterize log risks for the original outcome, not ordinary log odds for that outcome. For dlnm::crosspred, use model.link = "log" explicitly for modified Poisson or augmented logistic risk-ratio models, and pass the outer object to use its robust covariance. Supplying the inner glm object instead uses that object's model-based covariance. A family method alone does not ensure automatic link detection by every other package.

Objects saved with an earlier version may not contain vcov or model. They must be refitted before the corresponding extraction method can be used. A full covariance matrix cannot be reconstructed from marginal standard errors alone.

See Also

rqlm, qlogist, ttemsm

Examples

Run this code
data(SGLT2i01)
fit <- rqlm(death36 ~ A + risk_score, data=SGLT2i01,
            family=poisson, eform=TRUE)
coef(fit)
vcov(fit)
family(fit)

Run the code above in your browser using DataLab