Skip to content

Add posterior predicted reporting delay to joint nowcasting session #130

@seabbs

Description

@seabbs
joint_reporting_delay_with_r_onsets <- joint_rt_fit |>
  gather_draws(reporting_delay[day]) |>
  ungroup() |>
  filter(.draw %in% sample(.draw, 100)) |>
  mutate(day = day - 1) # Stan's indexing starts from 1, not zero!

reporting_delay_pmf_df = cbind(day=0:15, pmf=reporting_delay_pmf)

ggplot() +
  geom_col(
    data=reporting_delay_pmf_df, mapping=aes(x = day, y = reporting_delay_pmf), alpha = 0.6
  ) +
  geom_line(
    data=joint_reporting_delay_with_r_onsets, mapping = aes(x = day, y = .value, group = .draw), alpha = 0.1, color="red") + 
  labs(title = "Reporting delay distribution, estimated (red) and observed (gray)", y="PMF")

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions