Skip to content

Control aspects of the last fit process


control_last_fit(verbose = FALSE, event_level = "first", allow_par = FALSE)



A logical for logging results (other than warnings and errors, which are always shown) as they are generated during training in a single R process. When using most parallel backends, this argument typically will not result in any logging. If using a dark IDE theme, some logging messages might be hard to see; try setting the tidymodels.dark option with options(tidymodels.dark = TRUE) to print lighter colors.


A single string containing either "first" or "second". This argument is passed on to yardstick metric functions when any type of class prediction is made, and specifies which level of the outcome is considered the "event".


A logical to allow parallel processing (if a parallel backend is registered).


control_last_fit() is a wrapper around control_resamples() and is meant to be used with last_fit().