Skip to contents

Plots the ROC curve from a roc_auc result.

Usage

plot_roc(roc_obj, main = "ROC Curve", ...)

Arguments

roc_obj

A list returned by roc_auc.

main

Title for the plot. Default "ROC Curve".

...

Additional arguments passed to plot.

Value

Invisible NULL. Called for side effect (plot).

Examples

truth <- matrix(c(0,1,0,0, 1,0,1,0, 0,1,0,1, 0,0,1,0), 4, 4)
scores <- matrix(c(0,.9,.1,.05, .9,0,.8,.1, .1,.8,0,.7, .05,.1,.7,0), 4, 4)
roc <- roc_auc(scores, truth)
plot_roc(roc)