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

Extensions for Ebola vignette #285

Open
athowes opened this issue Sep 5, 2024 · 6 comments
Open

Extensions for Ebola vignette #285

athowes opened this issue Sep 5, 2024 · 6 comments
Labels
low For a future release

Comments

@athowes
Copy link
Collaborator

athowes commented Sep 5, 2024

The Ebola vignette (#52) is really big. So for now we will cut the parts about Gamma and model comparison. I'm going to paste things here that are cut, and eventually write out possible extensions.

Edit:

So my read of the possible extension is:

  • Model comparison with loo to show that (probably) sex-district stratified model is best
  • Fit gamma delay with best model
  • Again model comparison for gamma vs. lognormal
@athowes athowes mentioned this issue Sep 5, 2024
9 tasks
@athowes
Copy link
Collaborator Author

athowes commented Sep 5, 2024

2. Fitting models with lognormal and gamma delay distributions.
4. Selecting between fitted models using the [`loo`](https://mc-stan.org/loo/) package.
## Model comparison

* Use `loo` and PSIS
* Find out if it's worth including sex as a covariate. Presumably yes given how different the delay distributions are
* Find out if it's worth including district as a random effects
  * What about spatially structured? Probably future work: how to include more structured random effects

# Using a gamma delay distribution

## Fitting 

* Just fit the best model from above here? Yes
* Going to do the sex stratified one for now

fit_sex_gamma <- epidist(
  data = obs_prep,
  formula = brms::bf(mu ~ 1 + sex, shape ~ 1 + sex),
  family = stats::Gamma(),
  algorithm = "laplace",
  refresh = 0,
  silent = 2,
  seed = 1
)

summary(fit_sex_gamma)

## Model selection

* Should we use the lognormal or gamma delay distribution?
* The likelihood family may also be specified in `epidist`
* Model comparison may be performed via the `loo` package
* Factors that we did not take into account in this vignette include
  * Age: this would be a simple extension of the model
  * Time: it is less clear how appropriate it is to include time as a covariate in the model. That said, I think it is an important future direction because I expect the time point during the epidemic to be a clear confounder of delay duration. Given epidemic start time varies by district, the "district" effects in the model currently are complicated by this fact

@athowes
Copy link
Collaborator Author

athowes commented Sep 16, 2024

Adding issues here left from clean-up:

@athowes athowes mentioned this issue Sep 16, 2024
12 tasks
@athowes athowes added the low For a future release label Sep 18, 2024
@athowes
Copy link
Collaborator Author

athowes commented Sep 26, 2024

Note @zsusswein expressed interest F2F in there being model comparison in this vignette!

@seabbs
Copy link
Contributor

seabbs commented Sep 27, 2024

I also heard about this and heard posterior predictions vs real data which makes a lot of sense

@zsusswein
Copy link

As a reader, I would also enjoy some nice prior predictive visualizations

@seabbs
Copy link
Contributor

seabbs commented Sep 30, 2024

There is a balance to be struck here with complexity vs useful info so may need to watch that and in some cases just signpost out to other vignettes where these details are covered.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
low For a future release
Projects
None yet
Development

No branches or pull requests

3 participants