This is the result container object returned by benchmark().

Format

R6::R6Class object.

Construction

bmr = BenchmarkResult$new(data)

Fields

Methods

S3 Methods

Examples

set.seed(123) bmr = benchmark(expand_grid( tasks = mlr_tasks$mget("iris"), learners = mlr_learners$mget(c("classif.featureless", "classif.rpart")), resamplings = mlr_resamplings$mget("cv") )) print(bmr)
#> <BenchmarkResult> of 20 experiments in 2 resamplings: #> resampling task learner classif.mmce #> cv iris rpart 0.07333333 #> cv iris featureless 0.80666667 #> #> Public: aggregated(), clone(), combine(), data, get_best(), learners, #> measures, resample_result(), resample_results, resamplings, tasks
bmr$tasks
#> task_hash task_id task #> 1: 118778cfb7b5918f iris <TaskClassif>
bmr$learners
#> learner_hash learner_id learner #> 1: a3aea4ed7bc571d2 featureless <LearnerClassifFeatureless> #> 2: d64806633203a6d5 rpart <LearnerClassifRpart>
bmr$resamplings
#> resampling_hash resampling_id resampling #> 1: e740f22253d1c2ee cv <ResamplingCV>
bmr$measures
#> measure_hash measure_id measure #> 1: c7a66ec863ba061f classif.mmce <MeasureClassifMMCE>
bmr$aggregated(objects = FALSE)
#> hash resampling_id task_id learner_id classif.mmce #> 1: 78f08b3ec3175f45 cv iris featureless 0.80666667 #> 2: 24cf82fe4fa281f5 cv iris rpart 0.07333333
rrs = bmr$resample_results print(rrs)
#> hash task_id learner_id resampling_id N #> 1: 78f08b3ec3175f45 iris featureless cv 10 #> 2: 24cf82fe4fa281f5 iris rpart cv 10
rr = bmr$resample_result(rrs$hash[1]) print(rr)
#> <ResampleResult> of learner 'iris' on task 'featureless' with 10 iterations #> Measure Min. 1st Qu. Median Mean 3rd Qu. Max. Sd #> classif.mmce 0.7333 0.8 0.8 0.8067 0.8 0.9333 0.05837
rr$experiment(1)$model
#> $tab #> #> setosa versicolor virginica #> 49 44 42 #> #> $features #> [1] "Petal.Length" "Petal.Width" "Sepal.Length" "Sepal.Width" #> #> attr(,"class") #> [1] "featureless"