Fixed effects regression {Rfast2}R Documentation

Fixed effects regression

Description

Fixed effects regression.

Usage

fe.lmfit(y, x, id)

Arguments

y

A numerical vector or a numerical matrix.

x

A numerical matrix with the predictor variables.

id

A vector with the subject ids. This can be factor or a numerical.

Details

The function performs fixed effects regression (within estimator) for panel (longitudinal) data. It can also handle unblanced designs. A main difference from the package "plm" is that it returns much fewer information, but much faster.

Value

A list including:

be

The beta coefficients.

fe

The fixed effect deviations.

residuals

The residuals of the linear model(s).

Author(s)

Michail Tsagris.

R implementation and documentation: Michail Tsagris mtsagris@uoc.gr.

References

https://www.econometrics-with-r.org/10-rwpd.html

See Also

cluster.lm, gee.reg, fipois.reg, wild.boot

Examples

y <- rnorm(100)
x <- rnorm(100)
id <- rep(1:10, 10)
mod <- fe.lmfit(y, x, id)

[Package Rfast2 version 0.1.5.2 Index]