Calculate the average precision
Examples
prediction <- data.frame(
value = c(0.1, 0.2, 0.3, 0.4, 0.5),
outcomeCount = c(0, 1, 0, 1, 1)
)
averagePrecision(prediction)
#> [1] 0.9166667
Calculate the average precision
prediction <- data.frame(
value = c(0.1, 0.2, 0.3, 0.4, 0.5),
outcomeCount = c(0, 1, 0, 1, 1)
)
averagePrecision(prediction)
#> [1] 0.9166667