tune::show_best() displays the top sub-models and their performance estimates.
Usage
# S3 method for class 'tune_race'
show_best(
x,
...,
metric = NULL,
eval_time = NULL,
n = 5,
call = rlang::current_env()
)Arguments
- x
The results of
tune_grid()ortune_bayes().- ...
For
select_by_one_std_err()andselect_by_pct_loss(), this argument is passed directly todplyr::arrange()so that the user can sort the models from most simple to most complex. That is, for a parameterp, pass the unquoted expressionpif smaller values ofpindicate a simpler model, ordesc(p)if larger values indicate a simpler model. At least one term is required for these two functions. See the examples below.- metric
A character value for the metric that will be used to sort the models. (See https://yardstick.tidymodels.org/articles/metric-types.html for more details). Not required if a single metric exists in
x. If there are multiple metric and none are given, the first in the metric set is used (and a warning is issued).- eval_time
A single numeric time point where dynamic event time metrics should be chosen (e.g., the time-dependent ROC curve, etc). The values should be consistent with the values used to create
x. TheNULLdefault will automatically use the first evaluation time used byx.- n
An integer for the maximum number of top results/rows to return.
- call
The call to be shown in errors and warnings.
