getROC: Calculates ROC Curve

Description Usage Arguments Value Examples

View source: R/getROC.R

Description

Calculates the ROC curve

Usage

1
getROC(score, response, resolution = 1000)

Arguments

score

a numeric vector with the scores from the prodictive model

response

a boolean (TRUE or FALSE) vector with the real values from the dataset

resolution

maximum resolution for the table, maximum rows

Value

dataframe with the values of the ROC curve.

Examples

1
2
3
4
score = runif(1000)
response = (score + rnorm(1000,0,0.1)) > 0.5
ROC = getROC(score, response)
plot(ROC$false_positive,ROC$true_positive,type="l")

danielfm123/dftools documentation built on July 17, 2021, 1 p.m.