View source: R/calculate_roc.R
verify_d | R Documentation |
Checks for two classes and gives a warning message indicating which level is assumed to be 0/1. Throws an error if more than two levels appear in D.
verify_d(D)
D |
Vector that will be checked for 2-class labels |
A vector the same length as D that takes values 0, indicating no disease or 1 indicating disease.
verify_d(c(1, 0, 1))
## Not run:
verify_d(c(TRUE, FALSE, TRUE)) #warning
verify_d(c("Dead", "Alive", "Dead")) #warning
verify_d(c("Disease", "Healthy", "Missing")) #error
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.