R/cal_auc.R

Defines functions cal_auc

Documented in cal_auc

#' @export
#' @importFrom zoo "rollmean"

cal_auc <- function(X, Y) {
  id <- order(X)
  sum(diff(X[id])*rollmean(Y[id],2))
}

Try the multiROC package in your browser

Any scripts or data that you put into this service are public.

multiROC documentation built on May 1, 2019, 10:11 p.m.