Learn R Programming

sROC (version 0.1-2)

AUC: Area Under Curve

Description

Compute the area under curve of estimated ROC curve.

Usage

AUC(ROC, method="Simpson", ngrid=256)

Arguments

ROC
a ``ROC'' object generated by kROC(...).
method
a character string giving the numerical integration method to be used. This must be either ``Simpson'' or ``Trapez''.
ngrid
the number of grids for numerical integration.

Value

An object of class ``AUC''.

Details

Compute the area under curve of estimated ROC curve.

See Also

kROC.

Examples

Run this code

set.seed(100)
n <- 200
x <- rlnorm(n, mean=2, sd=1)
y <- rnorm(n,mean=2,sd=2)

xy.ROC <- kROC(c(x,NA,NA),c(y,1.2, NA), na.rm=TRUE)
plot(xy.ROC)
AUC(xy.ROC)
	

Run the code above in your browser using DataLab