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

Create delay_summary function built on predict_delay_parameters #215

Closed
Tracked by #238
athowes opened this issue Jul 31, 2024 · 5 comments
Closed
Tracked by #238

Create delay_summary function built on predict_delay_parameters #215

athowes opened this issue Jul 31, 2024 · 5 comments
Labels
high Required for next release

Comments

@athowes
Copy link
Collaborator

athowes commented Jul 31, 2024

Can use something like:

  summarised_draws <- draws[,
    list(
      mean = mean(value, na.rm = TRUE),
      median = median(value, na.rm = TRUE),
      q2.5 = quantile(value, 0.025, na.rm = TRUE),
      q5 = quantile(value, 0.05, na.rm = TRUE),
      q20 = quantile(value, 0.2, na.rm = TRUE),
      q35 = quantile(value, 0.35, na.rm = TRUE),
      q65 = quantile(value, 0.65, na.rm = TRUE),
      q80 = quantile(value, 0.8, na.rm = TRUE),
      q95 = quantile(value, 0.95, na.rm = TRUE),
      q97.5 = quantile(value, 0.975, na.rm = TRUE)
    ),
    by = by_cols
  ]

Main questions here for me are handling of how we name the groups for the samples. I think this will have interplay with #213 and the possible output of that function.

For example do we just want numbers like 1, ... or do we want to have different columns like age, location, sex, ... and then the corresponding samples (and eventually summaries). Should mention that in issue #213.

@seabbs
Copy link
Contributor

seabbs commented Jul 31, 2024

We could also just write a summary.delay_samples method

@athowes athowes changed the title Create delay_summary function built on delay_samples Create delay_summary function built on predict_delay_parameters Aug 2, 2024
@athowes
Copy link
Collaborator Author

athowes commented Aug 2, 2024

See here for maybe useful resource on this: https://github.com/epiforecasts/scoringutils/pull/876/files

@seabbs
Copy link
Contributor

seabbs commented Aug 5, 2024

I don't think that is useful?

I think our main choice is :

  1. summary method
  2. aggregate method
  3. our own custom s3.

Do we want to build predict_delay_parameters or just use brms functionality directly to get delay samples (i.e posterior prediction with new data).

@athowes
Copy link
Collaborator Author

athowes commented Aug 5, 2024

I thought that you had sent the scoringutils link above with the suggestion that it'd be useful for this issue. Did you mean it'd be useful for another issue? If so, which?

@athowes athowes added the high Required for next release label Aug 8, 2024
@athowes athowes mentioned this issue Aug 9, 2024
3 tasks
@athowes
Copy link
Collaborator Author

athowes commented Aug 11, 2024

I'm moving this to not planned for the time being as I expect this can be handled by tidybayes after some initial investigation.

@athowes athowes closed this as not planned Won't fix, can't repro, duplicate, stale Aug 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
high Required for next release
Projects
None yet
Development

No branches or pull requests

2 participants