Learn R Programming

plmmr (version 4.2.3)

coef.cv_plmm: Coef method for "cv_plmm" class

Description

Coef method for "cv_plmm" class

Usage

# S3 method for cv_plmm
coef(object, lambda, which = object$min, ...)

Value

Returns a named numeric vector. Values are the coefficients of the model at the specified value of either lambda or which. Names are the values of lambda.

Arguments

object

An object of class "cv_plmm."

lambda

A numeric vector of lambda values.

which

Vector of lambda indices for which coefficients to return. Defaults to lambda index with minimum CVE.

...

Additional arguments (not used).

Examples

Run this code
cv_fit <- cv_plmm(admix$X, admix$y, return_fit = TRUE)
head(coef(cv_fit))

Run the code above in your browser using DataLab