View source: R/mod_penalized.R
| mod_penalized | R Documentation | 
Fits a GLM penalized model using k-fold cross-validation to tune the lambda hyperparameter
mod_penalized( data, x_names = character(), y_name, alpha = 1, type_measure = "mse" )
data | 
 A numeric dataset in matrix-convertible format  | 
x_names | 
 A character vector of explainatory variables names  | 
y_name | 
 A character naming the variable to explain  | 
alpha | 
 A numeric to compromise between ridge (alpha=0) and lasso (alpha=1, default) penalization  | 
type_measure | 
 A character naming the error metric used for the cross-validation (defaults to "mse")  | 
The fitted model
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.