plot.AROC | R Documentation |
Takes a fitted AROC
object produced by AROC.bnp()
, AROC.sp()
, or AROC.kernel()
and plots the covariate-adjusted ROC curve (AROC) and associated area under the AROC (AAUC).
## S3 method for class 'AROC'
plot(x, main = NULL, ...)
x |
An object of class |
main |
Character string with the overall title for the plot. If NULL, the default, the method used to estimate the AROC curve is depicted. |
... |
Further arguments passed to or from other methods. |
AROC.bnp
, AROC.sp
or AROC.kernel
library(ROCnReg)
data(psa)
# Select the last measurement
newpsa <- psa[!duplicated(psa$id, fromLast = TRUE),]
# Log-transform the biomarker
newpsa$l_marker1 <- log(newpsa$marker1)
AROC_bnp <- AROC.bnp(formula.h = l_marker1 ~ f(age, K = 0),
group = "status", tag.h = 0, data = newpsa, standardise = TRUE,
p = seq(0,1,l=101), compute.lpml = TRUE, compute.WAIC = TRUE,
compute.DIC = TRUE)
plot(AROC_bnp)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.