Skip to content
New issue

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

only have second prep() throw warning if training argument is specified #1268

Merged
merged 1 commit into from
Nov 28, 2023

Conversation

EmilHvitfeldt
Copy link
Member

Both of the following used to throw the warning on main which is too much

library(recipes)

rec <- recipe(~ ., data = mtcars) |>
  step_center(mpg, disp) |>
  prep()

tmp <- rec |> prep()
tmp <- rec |> prep(training = mtcars)
#> Warning in prep(rec, training = mtcars): 
#> ! The previous data will be used by `prep()`.
#> ℹ The data passed using `training` will be ignored.

@EmilHvitfeldt EmilHvitfeldt merged commit 432cded into main Nov 28, 2023
9 checks passed
@EmilHvitfeldt EmilHvitfeldt deleted the prep-improve branch November 28, 2023 23:13
Copy link

This pull request has been automatically locked. If you believe you have found a related problem, please file a new issue (with a reprex https://reprex.tidyverse.org) and link to this issue.

@github-actions github-actions bot locked and limited conversation to collaborators Dec 13, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant