Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove spoiler callout to make a forecast plot #128

Open
avallecam opened this issue Oct 23, 2024 · 0 comments
Open

remove spoiler callout to make a forecast plot #128

avallecam opened this issue Oct 23, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@avallecam
Copy link
Member

In this episode section: https://epiverse-trace.github.io/tutorials-middle/create-forecast.html#forecasting-secondary-observations

We added this temporal patch:

:::::::::::::::: spoiler
### make a forecast plot
```{r}
deaths_forecast %>%
purrr::pluck("predictions") %>%
ggplot(aes(x = date, y = secondary)) +
geom_col(
fill = "grey", col = "white",
show.legend = FALSE, na.rm = TRUE
) +
geom_ribbon(aes(ymin = lower_90, ymax = upper_90),
alpha = 0.2, linewidth = 1) +
geom_ribbon(aes(ymin = lower_50, ymax = upper_50),
alpha = 0.4, linewidth = 1) +
geom_ribbon(aes(ymin = lower_20, ymax = upper_20),
alpha = 0.6, linewidth = 1) +
theme_bw() +
labs(y = "Reports per day", x = "Date") +
scale_x_date(date_breaks = "week", date_labels = "%b %d") +
scale_y_continuous(labels = scales::comma) +
theme(axis.text.x = ggplot2::element_text(angle = 90))
```
::::::::::::::::

Remove it after this issue in EpiNow2 gets fixed epiforecasts/EpiNow2#702

@avallecam avallecam added the bug Something isn't working label Oct 23, 2024
@avallecam avallecam moved this to Todo in tutorials-planning Oct 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Todo
Development

No branches or pull requests

1 participant