Skip to content

Commit

Permalink
Use keep_original_cols in Ch 19
Browse files Browse the repository at this point in the history
  • Loading branch information
juliasilge committed Jun 13, 2022
1 parent f751ddb commit 817180f
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions 19-when-should-you-trust-predictions.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -240,9 +240,7 @@ base_recipe <-
recipe(ridership ~ ., data = Chicago_train) %>%
# Create date features
step_date(date) %>%
step_holiday(date) %>%
# Change date to be an id column instead of a predictor
update_role(date, new_role = "id") %>%
step_holiday(date, keep_original_cols = FALSE) %>%
# Create dummy variables from factor columns
step_dummy(all_nominal()) %>%
# Remove any columns with a single unique value
Expand Down

0 comments on commit 817180f

Please sign in to comment.