Collect tuning metrics
Usage
ci_collect_metrics(
x,
summarize = TRUE,
metric = NULL,
...,
selected = NULL,
format = c("default", "tidy", "wide"),
include_train = TRUE
)Arguments
- x
A tuning object returned by
tune_ci_tree()ortune_ci_forest().- summarize
Logical; return grid-level summaries when
TRUE, or fold-level metrics whenFALSE. Ignored whenformat = "tidy".- metric
Optional metric name used to filter the result.
- ...
Reserved for future extensions.
- selected
Optional tuning summary rows, typically from
ci_select_best(), used to filter the returned metrics to selectedtype/grid_idcombinations.- format
Output format.
"default"preserves the package's original summary or fold-level table."tidy"returns a tidymodels-like table with grid columns followed by.metric,.estimator,mean,n,std_err,.dataset, and.config."wide"returns one row per tuning setting with metric columns such asmean_validation_gainandstd_err_train_gain.- include_train
Logical; for
format = "tidy"or"wide", include training diagnostic rows when the tuning object contains training diagnostics.