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

Figure 2 rough draft components #100

Merged
merged 22 commits into from
Jul 17, 2024
Merged

Figure 2 rough draft components #100

merged 22 commits into from
Jul 17, 2024

Conversation

kaitejohnson
Copy link
Collaborator

The point of this figure is to show an example comparing the forecasts of the wastewater model and the hospital admissions model for a few states (can decide on the states later), paired with the fits/forecasts to a subset of the wastewater data for that state.

This PR creates (separately) the ggplot components for the example hospital admissions forecasts colored by model type + the fits and forecasts to the wastewater concentrations for those example states.

See private repo for produced figures.

Note: The goal here is just to have the structure in place to generate the figures. All formatting decisions will be made in a second round of revisions. Am still using the {targets} pipeline for creating all of these, which enables caching and allows us to pass the post-processed objects/ mix analysis in with figure production when needed.

Copy link
Collaborator

@dylanhmorris dylanhmorris left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks largely good. A couple minor comments.

scratch/temp_ms_figs.R Outdated Show resolved Hide resolved
_targets_eval_postprocessing.R Show resolved Hide resolved
@kaitejohnson kaitejohnson marked this pull request as draft July 14, 2024 22:02
@kaitejohnson
Copy link
Collaborator Author

Converting back to a draft because I realized I forgot to make the second half of what was planned for Fig 2 (the forecast comparison plots by location and horizon, with CRPS underlaid)

@kaitejohnson kaitejohnson marked this pull request as ready for review July 15, 2024 18:14
@kaitejohnson
Copy link
Collaborator Author

Ok @dylanhmorris this is ready for review. Let me know if you'd prefer I just put all the figures in one PR, I figured breaking it up would be slightly easier. All the drafts are in the link to the cdcent repo issue.

In order to make the completed planned figure 2, we'd have to repeat a bunch of generations of the subpanels for the different locations, I left that out of the targets pipeline for now.

Copy link
Collaborator

@dylanhmorris dylanhmorris left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A couple minor but key questions @kaitejohnson

wweval/R/manuscript_figs.R Outdated Show resolved Hide resolved
wweval/R/manuscript_figs.R Outdated Show resolved Hide resolved
wweval/R/manuscript_figs.R Outdated Show resolved Hide resolved
@kaitejohnson
Copy link
Collaborator Author

@dylanhmorris Let me know what you think of this. I added the additional horizon_weeks and horizon columns upstream when creating the long form of the quantiles and the scores, and then pass them in to the figure functions. I think this will avoid redundancy.

I still have an open question about what horizon_week to assigned the forecast date (see my teams post). Once we've reached a consensus will edit that.

@kaitejohnson
Copy link
Collaborator Author

Update, going to switch to creating horizon_days folder and then creating categorical horizon columns from that. Going to lump the forecast date into the nowcast, since in theory, you could have partially observed data on the day you are making a forecast

@kaitejohnson
Copy link
Collaborator Author

Ok this is ready for re-review, let me know if you want me to make them into one function though @dylanhmorris

wweval/R/add_horizons.R Outdated Show resolved Hide resolved
wweval/R/add_horizons.R Show resolved Hide resolved
wweval/R/add_horizons.R Outdated Show resolved Hide resolved
wweval/R/add_horizons.R Outdated Show resolved Hide resolved
_targets_eval_postprocessing.R Outdated Show resolved Hide resolved
Copy link
Collaborator

@dylanhmorris dylanhmorris left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. One documentation wording suggestion.

wweval/R/add_horizons.R Outdated Show resolved Hide resolved
Co-authored-by: Dylan H. Morris <[email protected]>
@dylanhmorris dylanhmorris merged commit 8f5d0e1 into prod Jul 17, 2024
5 checks passed
@dylanhmorris dylanhmorris deleted the 84-fig2-components branch July 17, 2024 21:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants