
Construct your own resampled performance measure.
Source:R/Measure_custom_resampled.R
makeCustomResampledMeasure.RdConstruct your own performance measure, used after resampling. Note that
individual training / test set performance values will be set to NA, you
only calculate an aggregated value. If you can define a function that makes
sense for every single training / test set, implement your own Measure.
Arguments
- measure.id
(
character(1))
Short name of measure.- aggregation.id
(
character(1))
Short name of aggregation.- minimize
(
logical(1))
Should the measure be minimized? Default isTRUE.- properties
(character)
Set of measure properties. For a list of values see Measure. Default ischaracter(0).- fun
(
function(task, group, pred, extra.args))
Calculates performance value from ResamplePrediction object. For rare cases you can also use the task, the grouping or the extra argumentsextra.args. -task(Task)
The task. -group(factor)
Grouping of resampling iterations. This encodes whether specific iterations 'belong together' (e.g. repeated CV). -pred(Prediction)
Prediction object. -extra.args(list)
See below.- extra.args
(list)
List of extra arguments which will always be passed tofun. Default is empty list.- best
(
numeric(1))
Best obtainable value for measure. Default is -InforInf, depending onminimize.- worst
(
numeric(1))
Worst obtainable value for measure. Default isInfor -Inf, depending onminimize.- measure.name
(
character(1))
Long name of measure. Default ismeasure.id.- aggregation.name
(
character(1))
Long name of the aggregation. Default isaggregation.id.- note
(character)
Description and additional notes for the measure. Default is “”.
See also
Other performance:
ConfusionMatrix,
calculateConfusionMatrix(),
calculateROCMeasures(),
estimateRelativeOverfitting(),
makeCostMeasure(),
makeMeasure(),
measures,
performance(),
setAggregation(),
setMeasurePars()