Skip to contents

Make figure that stratifies across location and forecast dates

Usage

plot_rel_score_dists_by_horizon(
  scores,
  target_model,
  baseline_model,
  metric_to_compare,
  horizons_to_show = c("nowcast", "1 wk", "4 wks", "overall")
)

Arguments

scores

output of scoringutils::score().

target_model

Model for which to plot relative scores

baseline_model

Baseline model for the relative scores

metric_to_compare

Metric for which to compute the relative score. One of "wis" or "crps". Passed as the metric_to_compare argument to scoringutils::get_pairwise_comparisons() via forecasttools::summarise_scores_with_baseline().

horizons_to_show

A vector of strings indicating the names of the horizon that we want to show on the plot, must be a subset of nowcast, 1 wk, 2 wks,3 wks, 4 wks and overall

Value

A ggplot object containing plots of the distribution of relative scores across location and forecast dates