Description Usage Arguments Value Examples
Optimize the ridge parameter lambda with k-fold cross-validation
1 | best_lambda(formula, data, nfold = 5, lambda_list, intercept = TRUE)
|
formula |
An object of class formula to describe how the model is fitted |
data |
A data frame |
nfold |
An optional number k for k-fold cross-validation, default = 5 |
lambda_list |
A numeric vector consisting of lambda candidates |
intercept |
An optional logical value to indicate if intercept is included, default = TRUE |
Return the best lambda value
1 2 3 4 5 6 7 8 9 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.