knitr::opts_chunk$set(collapse = TRUE, comment = "#>")
This vignette shows how to perform Receiver Operating Characteristic
(ROC) analysis with meddecide using the psychopdaroc()
function.
df_roc <- read.csv(system.file("extdata", "roc_example.csv", package = "meddecide")) head(df_roc)
roc_res <- psychopdaroc(data = df_roc, class = df_roc$class, value = df_roc$value) roc_res$plot
The resulting plot shows the ROC curve along with the area under the curve (AUC). You can extract the AUC value and other statistics from the result object.
roc_res$AUC
auc_ci()
and bootstrap_ci()
provide convenience wrappers for computing
confidence intervals for diagnostic metrics.
auc_ci(roc_res) bootstrap_ci(roc_res)
These utilities allow you to assess the stability of your ROC analysis.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.