We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
forge_predictors()
Reprex:
library(workflows) library(parsnip) library(recipes) rec_spec <- recipe(mpg ~ ., data = mtcars) %>% update_role(disp, new_role = "date") %>% step_center(disp) lm_spec <- linear_reg() wf_spec <- workflow(rec_spec, lm_spec) wf_fit <- fit(wf_spec, data = mtcars) predict(wf_fit, mtcars %>% select(-disp)) #> Error in `hardhat::forge()`: #> ! The required column "disp" is missing.
The text was updated successfully, but these errors were encountered:
without spending too much time right now, i suppect it might be somewhere in {hardhat} that is the issue. Here is the traceback
▆ 1. ├─stats::predict(wf_fit, mtcars %>% select(-disp)) 2. └─workflows:::predict.workflow(wf_fit, mtcars %>% select(-disp)) 3. └─workflows:::forge_predictors(new_data, workflow) 4. ├─hardhat::forge(new_data, blueprint = mold$blueprint) 5. └─hardhat:::forge.data.frame(new_data, blueprint = mold$blueprint) 6. ├─hardhat::run_forge(blueprint, new_data = new_data, outcomes = outcomes) 7. └─hardhat:::run_forge.default_recipe_blueprint(...) 8. └─hardhat:::forge_recipe_default_clean(...) 9. └─hardhat:::forge_recipe_default_clean_extras(...) 10. └─hardhat:::map(...) 11. └─base::lapply(.x, .f, ...) 12. └─hardhat (local) FUN(X[[i]], ...) 13. └─hardhat::validate_column_names(data, cols, call = call) 14. └─cli::cli_abort(...) 15. └─rlang::abort(...)
Sorry, something went wrong.
No branches or pull requests
Reprex:
The text was updated successfully, but these errors were encountered: