specificity: Compute the specificity curve.

View source: R/measures.R

specificityR Documentation

Compute the specificity curve.

Description

This function computes the specificity curve required for the auc function and the plot function.

Usage

specificity(predictions, labels, perc.rank = TRUE)

Arguments

predictions

A numeric vector of classification probabilities (confidences, scores) of the positive event.

labels

A factor of observed class labels (responses) with the only allowed values {0,1}.

perc.rank

A logical. If TRUE (default) the percentile rank of the predictions is used.

Value

A list containing the following elements:

cutoffs

A numeric vector of threshold values

measure

A numeric vector of specificity values corresponding to the threshold values

Author(s)

Authors: Michel Ballings and Dirk Van den Poel, Maintainer: Michel.Ballings@UGent.be

References

Ballings, M., Van den Poel, D., Threshold Independent Performance Measures for Probabilistic Classifcation Algorithms, Forthcoming.

See Also

sensitivity, specificity, accuracy, roc, auc, plot

Examples


data(churn)

specificity(churn$predictions,churn$labels)


AUC documentation built on April 5, 2022, 1:15 a.m.