Functions for plots that assess forecast calibration Get quantile-quantile plot
Source:R/plot_calibration.R
forecast_qq_plot.Rd
Adapted from MIT-licensed scoringutils::plot_quantile_coverage()
.
Usage
forecast_qq_plot(
forecasts,
model_z_order = NULL,
linewidth = 2,
reference_linecolor = "gray",
reference_linewidth = 2,
reference_linetype = "dashed",
...
)
Arguments
- forecasts
df of granular (daily) quantile forecasts
- model_z_order
z-order in which to overplot the individual models, ascending (so the last named model is plotted on top). If
NULL
(default), plot the models in the order they appear inforecasts
.- linewidth
width
parameter for the Q-Q lines for individual models. Default 2.- reference_linecolor
color
parameter for the r eference y = x line. Default"gray"
.- reference_linewidth
width
parameter for the reference y = x line. Default2
.- reference_linetype
linetype
parameter for the reference y = x line. Default"dashed"
.- ...
additional keyword arguments passed to
ggplot2::geom_line()
for the Q-Q lines for individual models.