View source: R/plot_scorecard.R
plot_scorecard | R Documentation |
This function is used to plot a score card from the output of a bootstrap verification function such as bootstrap_verify.
plot_scorecard(
bootstrap_data,
fcst_model,
ref_model,
scores,
facet_by = vars(score),
num_facet_rows = 1,
grid_facets = FALSE,
filter_by = NULL,
significance_breaks = c(-1.1, -0.997, -0.95, -0.68, 0.68, 0.95, 0.997, 1.1),
colours = c("#CA0020", "#CA0020", "#CA0020", "grey70", "#0571B0", "#0571B0", "#0571B0"),
fills = c("#CA0020", "#F4A582", NA, "grey70", NA, "#92C5DE", "#0571B0"),
shapes = c(25, 25, 25, 22, 24, 24, 24),
sizes = c(3, 2, 1, 0.5, 1, 2, 3),
legend_labels = "auto",
num_facet_cols = length(scores),
...
)
bootstrap_data |
The output from bootstrap_verify. |
fcst_model |
The forecast model of interest. |
ref_model |
The forecast model to be used as reference. |
scores |
Vector of scores to include in the plot. |
facet_by |
Column(s) to facet panels by - should be unquoted and wrapped
in the |
filter_by |
Filtering function - column names should be unquoted and
everything wrapped inside the |
significance_breaks |
The breaks to for statistical significance of
differences. Default is |
colours |
Vector of outline colours used for the scorecard symbols.
Should be one fewer then |
fills |
Vector of fill colours used for the scorecard symbols. Should be
one fewer then |
shapes |
Vector of shapes used for the scorecard symbols. Should be one
fewer then |
sizes |
Vector of sizes used for the scorecard symbols. Should be one
fewer then |
legend_labels |
Character vector of labels to be used for the scorecard
symbols. Should be one fewer then |
num_facet_cols |
Number of panel columns in the score card. |
A score card plot. Can be saved with ggsave
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.