Set Up a ROC Plot Configuration
Usage
setup_ROCConfig(
fpr = "fpr",
tpr = "tpr",
auc = NULL,
class_label = NULL,
split = NULL,
fold = NULL,
omitted = NULL,
variant = "aggregate",
digits = 3L,
diagonal = TRUE,
diagonal_color = "#888888",
palette = NULL,
legend = TRUE,
legend_position = "top",
legend_placement = "outside",
legend_title = NULL,
square = TRUE,
line_width = 2,
fold_opacity = 0.45,
xlab = "False positive rate",
ylab = "True positive rate",
title = NULL,
dat_path = NULL,
origin = NULL,
writer = NULL
)Arguments
- fpr
Character: Column containing false positive rates.
- tpr
Character: Column containing true positive rates.
- auc
Optional Character: Optional supplied AUC column; unset integrates the supplied vertices.
- class_label
Optional Character: Optional positive-class label column.
- split
Optional Character: Optional sample or model label column.
- fold
Optional Character: Optional resample column; aggregate identifies pooled curves.
- omitted
Optional Character: Optional omitted-observation count column, constant within each curve.
- variant
Character: Draw pooled curves or separate resample curves.
- digits
Integer: Decimal places for AUC labels and tooltip values.
- diagonal
Logical: Show an independent chance diagonal.
- diagonal_color
Character: Chance-line color.
- palette
Optional Character: Group colors; unset uses the chart theme.
- legend
Logical: Show group labels and AUC summaries.
- legend_position
Character {"top", "bottom", "left", "right", "top-left", "top-right", "bottom-left", "bottom-right"}: Legend anchor. Top/bottom anchors use horizontal rows; left/right anchors use a vertical column. Corner anchors align within the top or bottom row.
- legend_placement
Character {"outside", "inside"}: Relation to the plotting area. Outside placement reserves space for the complete legend; inside placement overlays the data. Neither setting adds a missing legend.
- legend_title
Optional Character: Title drawn with the legend or colorbar: above left/right legends and vertical colorbars, before the first row of top/bottom legends and horizontal colorbars.
NULLdraws no title. A title does not add a missing legend.- square
Logical: Keep the plotting grid square.
- line_width
Numeric: Curve stroke width in pixels.
- fold_opacity
Numeric: Opacity of individual resample curves.
- xlab
Character: Horizontal axis label.
- ylab
Character: Vertical axis label.
- title
Optional Character: Chart title.
- dat_path
Optional Character: Path to the data, read at draw time. The serializable alternative to passing
datatodraw().- origin
Optional Named character: Per-property provenance.
- writer
Optional Named character: Interface name and version.
Value
A ROCConfig object.
Examples
setup_ROCConfig(class_label = "class", split = "split", fold = "fold", auc = "auc")#> <ROCConfig>
#>
#> type: <chr> roc
#> dat_path: <NUL> NULL
#> title: <NUL> NULL
#> origin: <chr> default, default, default, default, ...
#> writer: <NUL> NULL
#> legend_position: <chr> top
#> legend_placement: <chr> outside
#> legend_title: <NUL> NULL
#> fpr: <chr> fpr
#> tpr: <chr> tpr
#> auc: <chr> auc
#> class_label: <chr> class
#> split: <chr> split
#> fold: <chr> fold
#> omitted: <NUL> NULL
#> variant: <chr> aggregate
#> digits: <int> 3
#> diagonal: <lgc> TRUE
#> diagonal_color: <chr> #888888
#> palette: <NUL> NULL
#> legend: <lgc> TRUE
#> square: <lgc> TRUE
#> line_width: <nmr> 2.00
#> fold_opacity: <nmr> 0.45
#> xlab: <chr> False positive rate
#> ylab: <chr> True positive rate
#>