npv {ModelMetrics} | R Documentation |
True Negatives / (True Negatives + False Negatives)
npv(actual, predicted, cutoff = 0.5)
actual |
A vector of the labels |
predicted |
A vector of predicted values |
cutoff |
A cutoff for the predicted values |
data(testDF)
glmModel <- glm(y ~ ., data = testDF, family="binomial")
Preds <- predict(glmModel, type = 'response')
npv(testDF$y, Preds, cutoff = 0)