Learn R Programming

asbio (version 1.0-5)

auc: Area under a reciever operating characterisitic (ROC) curve

Description

A simple algortihm for calculating emph{AUC}.

Usage

auc(obs, fit, plot = FALSE)

Arguments

obs
Dichotomous {0, 1} outcomes (i.e. response values for binomial GLM).
fit
Fitted probabilities from some model.
plot
Logical, indicating whether or not ROC curve plot should be created.

References

Agresti, A. (2012) Categorical data analysis, 3rd edition. New York. Wiley.

Examples

Run this code
obs <-rbinom(30, 1, 0.5)
fit <- rbeta(30, 1, 2)

auc(obs, fit)

Run the code above in your browser using DataLab