Creates a cost measure for non-standard classification error costs.

makeCostMeasure(
id = "costs",
minimize = TRUE,
costs,
combine = mean,
best = NULL,
worst = NULL,
name = id,
note = ""
)

## Arguments

id (character(1)) Name of measure. Default is “costs”. (logical(1)) Should the measure be minimized? Otherwise you are effectively specifying a benefits matrix. Default is TRUE. (matrix) Matrix of misclassification costs. Rows and columns have to be named with class labels, order does not matter. Rows indicate true classes, columns predicted classes. (function) How to combine costs over all cases for a SINGLE test set? Note this is not the same as the aggregate argument in makeMeasure You can set this as well via setAggregation, as for any measure. Default is mean. (numeric(1)) Best obtainable value for measure. Default is -Inf or Inf, depending on minimize. (numeric(1)) Worst obtainable value for measure. Default is Inf or -Inf, depending on minimize. (character) Name of the measure. Default is id. (character) Description and additional notes for the measure. Default is “”.

## Value

Other performance: ConfusionMatrix, calculateConfusionMatrix(), calculateROCMeasures(), estimateRelativeOverfitting(), makeCustomResampledMeasure(), makeMeasure(), measures, performance(), setAggregation(), setMeasurePars()