Usage
calculate_roc(M, D, ci = FALSE, alpha = 0.05)
Arguments
- M
continuous marker values or predictions of class labels
- D
class labels, must be coded as 0 and 1. If not numeric with 0/1,
then plotROC assumes the first level in sort order is healthy status, with
a warning.
- ci
Logical, if true, will calculate exact joint confidence regions for
the TPF and FPF
- alpha
Confidence level, ignored if ci = FALSE
Value
A dataframe containing cutoffs, estimated true and false positive
fractions, and confidence intervals if ci = TRUE.
Details
Confidence intervals for TPF and FPF are calculated using the exact
method of Clopper and Pearson (1934) each at the level 1 - sqrt(1 -
alpha). Based on result 2.4 from Pepe (2003), the cross-product of these
intervals yields a 1 - alpha