Revision 272ac623c984dbf5defce76b6495c05accafe79f authored by Patrick Schratz on 17 December 2019, 04:08:28 UTC, committed by Patrick Schratz on 17 December 2019, 04:08:28 UTC
Build URL: https://circleci.com/gh/mlr-org/mlr/1264
Commit:
1 parent 9de9c6e
Raw File
getConfMatrix.Rd
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/getConfMatrix.R
\name{getConfMatrix}
\alias{getConfMatrix}
\title{Confusion matrix.}
\usage{
getConfMatrix(pred, relative = FALSE)
}
\arguments{
\item{pred}{(\link{Prediction})\cr
Prediction object.}

\item{relative}{(\code{logical(1)})\cr
If \code{TRUE} rows are normalized to show relative frequencies.
Default is \code{FALSE}.}
}
\value{
(\link{matrix}). A confusion matrix.
}
\description{
\code{getConfMatrix} is deprecated. Please use \link{calculateConfusionMatrix}.

Calculates confusion matrix for (possibly resampled) prediction.
Rows indicate true classes, columns predicted classes.

The marginal elements count the number of classification
errors for the respective row or column, i.e., the number of errors
when you condition on the corresponding true (rows) or predicted
(columns) class. The last element in the margin diagonal
displays the total amount of errors.

Note that for resampling no further aggregation is currently performed.
All predictions on all test sets are joined to a vector yhat, as are all labels
joined to a vector y. Then yhat is simply tabulated vs y, as if both were computed on
a single test set. This probably mainly makes sense when cross-validation is used for resampling.
}
\seealso{
\link{predict.WrappedModel}
}
back to top