Learn R Programming

plmm (version 0.1-1)

residuals: Extract Model Residuals

Description

Extract residuals from a model fitted using a model fitting function plmm or wplmm. resid is an alias.

Usage

"residuals"(object,...) "residuals"(object,...) "resid"(object,...) "resid"(object,...)

Arguments

object
a model fitted with plmm or wplmm.
...
other arguments.

Details

The residual is defined as the value obtained by subtracting from the response value the estimated fixed components and the predicted random intercept of the cluster the observational unit of the response belongs to.

See Also

plmm, wplmm

Examples

Run this code
data(plmm.data)
model <- plmm(y0~x1+x2+x3|t1, random=cluster, data=plmm.data)
residuals(model)

Run the code above in your browser using DataLab