library(ggplot2)
library(magrittr)
example_continuous %>%
  make_NA (
    what = "truth",
    target_end_date >= "2021-07-22",
    target_end_date < "2021-05-01"
  ) %>%
  make_NA (
    what = "forecast",
    model != "EuroCOVIDhub-ensemble",
    forecast_date != "2021-06-07"
  ) %>%
  plot_predictions (
    x = "target_end_date",
    by = c("target_type", "location"),
    range = c(0, 50, 90, 95)
  ) +
  facet_wrap(~ location + target_type, scales = "free_y") +
  aes(fill = model, color = model)
example_continuous %>%
  make_NA (
    what = "truth",
    target_end_date >= "2021-07-22",
    target_end_date < "2021-05-01"
  ) %>%
  make_NA (
    what = "forecast",
    forecast_date != "2021-06-07"
  ) %>%
  plot_predictions (
    x = "target_end_date",
    by = c("target_type", "location"),
    range = c(0)
  ) +
  facet_wrap(~ location + target_type, scales = "free_y") +
  aes(fill = model, color = model)
Run the code above in your browser using DataLab