Description Usage Arguments Value Examples
Roc curve
| 1 | 
| x | a numerical vector | 
| y | represent logical class TRUE/FALSE. | 
| file | name of output file for saving roc curve plot. | 
| AUC | return auc value AUC = TRUE | 
Return roc curve values: TPR, FPR or AUC
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 | 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)]
perfect.x <- 1:3000
perfect.y <- c(rep(TRUE, 1500), rep(FALSE, 1500))
worst.x <- 1:3000
worst.y <- c(rep(FALSE, 1500), rep(TRUE, 1500))
roc.curve(random.x, random.y, file= "randomRocCurve")
roc.curve(perfect.x, perfect.y, file= "perfectRocCurve")
roc.curve(worst.x, worst.y, file= "worstRocCurve") 
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.