slopes: Extract individual slopes

View source: R/feis.R

slopesR Documentation

Extract individual slopes

Description

Extracts the individual slopes (alpha_i) from a feis object created by feis.

Usage

slopes(model = NA, ...)

Arguments

model

an object of class "feis".

...

further arguments.

Details

The function extracts a matrix containing the individual slope parameters (alpha_i), which equals the coefficient(s) of regressing the depenent variable on the slope parameter(s).

If slope variables are perfectly collinear within a cluster, one variable is dropped and the function returns 0 for the respective slope and cluster.

Value

An N x J matrix containing the individual slopes for each cluster unit N and slope variable J. Rownames indicate the cluster id.

Examples

data("Produc", package = "plm")
feis.mod <- feis("log(gsp) ~ log(pcap) + log(pc) + log(emp) + unemp | year",
                 data = Produc, id = "state", robust = TRUE)
slps <- slopes(feis.mod)


feisr documentation built on April 1, 2022, 5:06 p.m.