Open topepo opened 5 years ago
We are catching this error differently now using the no_penalty()
function. The error pops up in submod_and_others()
if the no_penalty()
check is ignored.
library(tidymodels)
rec_no_tune_1 <-
recipe(mpg ~ ., data = mtcars) %>%
step_normalize(all_predictors())
glmn_mod <- linear_reg(mixture = tune(), penalty = .1) %>% set_engine("glmnet")
set.seed(363)
mt_folds <- vfold_cv(mtcars, v = 5)
workflow() %>%
add_recipe(rec_no_tune_1) %>%
add_model(glmn_mod) %>%
tune_grid(mt_folds)
#> Error: At least one penalty value is required for glmnet.
Created on 2022-02-18 by the reprex package (v2.0.1)
Created on 2019-09-04 by the reprex package (v0.2.1)