Learn R Programming

rtemis (version 0.79)

mplot3.confbin: Plot extended confusion matrix for binary classification

Description

Plots an extended confusion matrix using mplot3.img

Usage

mplot3.confbin(object, main = NULL, xlab = "True",
  ylab = "Estimated", mod.name = NULL, mar = c(4, 5, 4, 3),
  dim.lab = 1, dim.in = 4, dim.out = 2, font.in = 2,
  font.out = 2, cex.in = 1.2, cex.lab = 1.2, cex.lab2 = 1,
  cex.out = 1, col.text.out = "white", col.bg.out = "gray50",
  theme = "light", mid.color = NULL, hi.color.pos = ucsfCol$teal,
  hi.color.neg = ucsfCol$purple, par.reset = TRUE, pdf.width = 8.7,
  pdf.height = 8.7, filename = NULL, ...)

Arguments

object

Either 1. a classification rtMod, b. a caret::confusionMatrix object, or c. a matrix / data.frame / table

main

String: Plot title

xlab

String: x-axis label

ylab

String: y-axis label

mod.name

String: Name of the algorithm used to make predictions. If NULL, will look for object$mod.name. Default = NULL

mar

Numeric, vector, length 4: Overall margins

dim.lab

Float: Height for labels

dim.in

Float: Width and height for confusion matrix cells

dim.out

Float: Height for metrics cells

font.in

Integer: The font parameter for confusion matrix cells

font.out

Integer: The font parameter for metrics cells

cex.in

Float: The cex parameter for confusion matrix cells

cex.lab

Float: The cex parameter for first line of label cells

cex.lab2

Float: The cex parameter for second line of label cells

cex.out

Float: The cex parameter for metrics cells

col.text.out

Color for metrics cells' text

col.bg.out

Color for metrics cells' background

theme

String: "light", or "dark"

mid.color

Color: The mid color for the confusion matrix. Default = "white" for theme = "light", "black" for "dark"

hi.color.pos

Color: The hi color for correct classification.

hi.color.neg

Color: The hi color for missclassification

par.reset

Logical: If TRUE, reset par before exit. Default = TRUE

pdf.width

Float: PDF width, if filename is set

pdf.height

Float: PDF height, if filename is set

filename

String: If specified, save plot to this path. Default = NULL

...

Not used

Value

List of metrics, invisibly