xrf (version 0.2.0)

coef.xrf: Produce rules & coefficients for the RuleFit model

Description

Produce rules & coefficients for the RuleFit model

Usage

# S3 method for xrf
coef(object, lambda = "lambda.min", ...)

Arguments

object

an object of class "xrf"

lambda

the lasso penalty parameter to be applied as in 'glmnet'

...

ignored arguments

Examples

Run this code
# NOT RUN {
m <- xrf(Petal.Length ~ ., iris,
         xgb_control = list(nrounds = 20, max_depth = 2),
         family = 'gaussian')
linear_model_coefficients <- coef(m, lambda = 'lambda.1se')

# }

Run the code above in your browser using DataCamp Workspace