Skip to contents

model_categorical_lasso

Usage

model_categorical_lasso(x, y)

Arguments

x

features/predictors used in prediction of outcome

y

categorical outcome to predict

Value

lasso results

Examples

x <- iris[, c("Sepal.Length", "Sepal.Width", "Petal.Length", "Petal.Width")]
y <- iris$Species
model_categorical_lasso(x, y)
#> 
#> Call:  glmnet(x = x, y = y, family = family, alpha = 1, lambda = cv$lambda.min) 
#> 
#>   Df %Dev   Lambda
#> 1  4 95.6 0.001239