Learn R Programming

ROCS (version 1.4)

e.roc: Calculating expected Receiver Operating Characteristics Curve in the presence of imperfect reference standards.

Description

This function builds an eROC curve and returns the expected values of TPR, FPR, and TDR. It also calculates the AUC of the eROC curve. The 95% bootstrap percentile confidence interval for the AUC is provided.

Usage

e.roc(x, mu, method='RNA', bt.ci=TRUE, bt.nreps=100, do.plot=TRUE)

Value

Returns the area under the eROC curve, the expected values of TPR, FPR, and TDR.

Arguments

x

Vector; the scores yielded by the classifier.

mu

Vector; the probabilistic confidence assigned by the imperfect reference standard.

method

The method used to compute the cumulative distribution function for the Poisson binomial distribution. ``DFT-CF'' for the DFT-CF method, ``RF'' for the recursive formula, ``RNA'' for the refined normal approximation, ``NA'' for the normal approximation.

bt.ci

Whether to compute the bootstrap confidence interval.

bt.nreps

The number of bootstrap replicates.

do.plot

Whether to plot the eROC curve.

Author

Peizhou Liao. Email: pliao3@emory.edu.

Details

The eROC curve is a generalization of ROC curve given the class membership uncertainties. See the reference for the definition of the eROC curve.

References

Liao P, Wu H, and Yu T (2016). ROC Curve Analysis in the Presence of Imperfect Reference Standards. Stat Biosci doi:10.1007/s12561-016-9159-7.

Examples

Run this code
## normal scores
sample.p <- rnorm(100, mean=1, sd=sqrt(2))  
sample.n <- rnorm(100, mean=-1, sd=sqrt(2))  

## probabilistic confidence
mu.p <- rbeta(100, shape1=5, shape2=1)
mu.n <- rbeta(100, shape1=1, shape2=5)

## combine the sample
x.sample <- c(sample.p, sample.n)
mu.sample <- c(mu.p, mu.n)

## build eROC curve
e.roc.fit <- e.roc(x=x.sample, mu=mu.sample)

Run the code above in your browser using DataLab