1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71
|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/Measure_make_cost.R
\name{makeCostMeasure}
\alias{makeCostMeasure}
\title{Creates a measure for non-standard misclassification costs.}
\usage{
makeCostMeasure(
id = "costs",
minimize = TRUE,
costs,
combine = mean,
best = NULL,
worst = NULL,
name = id,
note = ""
)
}
\arguments{
\item{id}{(\code{character(1)})\cr
Name of measure.
Default is \dQuote{costs}.}
\item{minimize}{(\code{logical(1)})\cr
Should the measure be minimized?
Otherwise you are effectively specifying a benefits matrix.
Default is \code{TRUE}.}
\item{costs}{(\link{matrix})\cr
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.}
\item{combine}{(\code{function})\cr
How to combine costs over all cases for a SINGLE test set?
Note this is not the same as the \code{aggregate} argument in \link{makeMeasure}
You can set this as well via \link{setAggregation}, as for any measure.
Default is \link{mean}.}
\item{best}{(\code{numeric(1)})\cr
Best obtainable value for measure.
Default is -\code{Inf} or \code{Inf}, depending on \code{minimize}.}
\item{worst}{(\code{numeric(1)})\cr
Worst obtainable value for measure.
Default is \code{Inf} or -\code{Inf}, depending on \code{minimize}.}
\item{name}{(\link{character}) \cr
Name of the measure. Default is \code{id}.}
\item{note}{(\link{character}) \cr
Description and additional notes for the measure. Default is \dQuote{}.}
}
\value{
\link{Measure}.
}
\description{
Creates a cost measure for non-standard classification error costs.
}
\seealso{
Other performance:
\code{\link{ConfusionMatrix}},
\code{\link{calculateConfusionMatrix}()},
\code{\link{calculateROCMeasures}()},
\code{\link{estimateRelativeOverfitting}()},
\code{\link{makeCustomResampledMeasure}()},
\code{\link{makeMeasure}()},
\code{\link{measures}},
\code{\link{performance}()},
\code{\link{setAggregation}()},
\code{\link{setMeasurePars}()}
}
\concept{performance}
|