auprc | R Documentation |
Balancing concept by Yingzhou Wu and Fritz Roth (Wu et al, unpublished)
auprc(yr2, monotonized = TRUE, balanced = FALSE)
yr2 |
the yogiroc2 object |
monotonized |
whether or not use a monotonized PRC curve |
balanced |
whether or not to use prior-balancing |
a numerical vector with the AUPRC values for each predictor
#generate fake data
truth <- c(rep(TRUE,10),rep(FALSE,8))
scores <- cbind(
pred1=c(rnorm(10,1,0.2),rnorm(8,.9,0.1)),
pred2=c(rnorm(10,1.1,0.2),rnorm(8,.9,0.2))
)
#create yogiroc2 object
yrobj <- yr2(truth,scores)
#calculate AUPRC
auprc(yrobj)
#calculate non-monotonized AUPRC
auprc(yrobj,monotonized=FALSE)
#calculate balanced AUPRC
auprc(yrobj,balanced=TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.