ranef.plmm: Random Effects Prediction

Description Usage Arguments Details Value Examples

View source: R/ranef.plmm.R

Description

Predict the random effects (intercepts) of a model fitted using a model fitting function plmm or wplmm.

Usage

1
2
3
4
## S3 method for class 'plmm'
ranef(object, data, ...)
## S3 method for class 'wplmm'
ranef(object, data, ...)

Arguments

object

a model fitted with plmm or wplmm.

data

an optional data frame containing the variables in the model. If relevant variables are not found in data, the variables are taken from the environment plmm was called from.

...

other arguments.

Details

The predictor is linear in the response. A random effect is predicted for each element of the clustering variable specified for random in the function call to plmm.

Value

A named vector of predicted random effects.

Examples

1
2
3
data(plmm.data)
model <- plmm(y0~x1+x2+x3|t1, random=cluster, data=plmm.data)
ranef(model, data=plmm.data)

plmm documentation built on May 2, 2019, 7:29 a.m.