Description Usage Arguments Value Examples
Plot Roc curve
1 | visualize.roc.curve(roc.FPR, roc.TPR, auc, file = "None")
|
roc.FPR |
a numerical vector representing false positive rates |
roc.TPR |
a numerical vector representing true positive rates |
auc |
auc value. Use auc() function. |
file |
name of output file for saving roc curve plot. |
Plot roc curve
1 2 3 4 5 6 7 8 | random.x <- sample.int(3000,1000,replace=FALSE)
class <- c(rep(TRUE, 500), rep(FALSE, 500))
pos <- sample.int(1000, 1000)
random.y <- class[order(pos)]
roc.curve <- roc.curve(random.x, random.y)
auc <- auc(roc.curve$FPR , roc.curve$TPR )
visualize.roc.curve(roc.curve$FPR , roc.curve$TPR, auc)
visualize.roc.curve(roc.curve$FPR , roc.curve$TPR, auc, file = "randomRocCurve")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.