draw_roc | R Documentation |
Draw ROC curve
draw_roc(
true_labels,
predicted_prob,
main = NULL,
theme = choose_theme(),
col = rtpalette(rtemis_palette),
legend = TRUE,
legend_title = "Group (AUC)",
legend_xy = c(1, 0),
legend_xanchor = "right",
legend_yanchor = "bottom",
auc_dp = 3L,
xlim = c(0, 1),
ylim = c(0, 1),
diagonal = TRUE,
diagonal_col = NULL,
axes_square = TRUE,
filename = NULL,
...
)
true_labels |
Factor: True outcome labels. |
predicted_prob |
Numeric vector [0, 1]: Predicted probabilities for the positive class (i.e. second level of outcome). |
main |
Character: Main title for the plot. |
theme |
Theme object. |
col |
Color vector. |
legend |
Logical: If TRUE, draw legend. |
legend_title |
Character: Title for the legend. |
legend_xy |
Numeric vector: Position of the legend in the form c(x, y). |
legend_xanchor |
Character: X anchor for the legend. |
legend_yanchor |
Character: Y anchor for the legend. |
auc_dp |
Integer: Number of decimal places for AUC values. |
xlim |
Numeric vector: Limits for the x-axis. |
ylim |
Numeric vector: Limits for the y-axis. |
diagonal |
Logical: If TRUE, draw diagonal line. |
diagonal_col |
Character: Color for the diagonal line. |
axes_square |
Logical: If TRUE, make axes square. |
filename |
Character: If provided, save the plot to this file. |
... |
Additional arguments passed to draw_scatter. |
plotly
object.
EDG
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.