recall: Recall, Sensitivity, tpr

Description Usage Arguments Examples

View source: R/ModelMetrics.R

Description

True Positives / (True Positives + False Negatives)

Usage

1
recall(actual, predicted, cutoff = 0.5)

Arguments

actual

A vector of the labels

predicted

A vector of predicted values

cutoff

A cutoff for the predicted values

Examples

1
2
3
4
5
6
7
data(testDF)
glmModel <- glm(y ~ ., data = testDF, family="binomial")
Preds <- predict(glmModel, type = 'response')

recall(testDF$y, Preds, cutoff = 0)
sensitivity(testDF$y, Preds, cutoff = 0)
tpr(testDF$y, Preds, cutoff = 0)

JackStat/ModelMetrics documentation built on Nov. 7, 2018, 5:19 a.m.