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

{simulist} full package review #33

Closed
wants to merge 184 commits into from
Closed

{simulist} full package review #33

wants to merge 184 commits into from

Conversation

joshwlambert
Copy link
Member

This PR is to provide a platform to review the entirety of the package.

Once this review concludes I will release v0.1.0 on GitHub. (#32).

This PR is unconventional as it is not intended for merging or for additional commits (unless minor) and instead comments will be converted to issues and these will be addressed in their own PRs.

@joshwlambert joshwlambert added the pkg review Full package review label Dec 5, 2023
Copy link

github-actions bot commented Dec 5, 2023

This pull request:

  • Adds 52 new dependencies (direct and indirect)
  • Adds 8 new system dependencies
  • Removes 0 existing dependencies (direct and indirect)
  • Removes 0 existing system dependencies

(Note that results may be inacurrate if you branched from an outdated version of the target branch.)

@pratikunterwegs pratikunterwegs self-requested a review December 6, 2023 11:49
@Bisaloo Bisaloo self-requested a review December 11, 2023 10:08
@CarmenTamayo CarmenTamayo self-assigned this Dec 11, 2023
Copy link
Member

@adamkucharski adamkucharski left a comment

Choose a reason for hiding this comment

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

Thanks for putting together, lots of useful functionality here. I've mostly focused on the vignettes – have suggested some tweaks to help users understand value of the package, as well as ensuring consistency in terminology etc. throughout.

The dependency on bpmodels is probably worth updating once stable epichains available. Would also be nice to include simulist outbreaks as comparisons in other packages (e.g. to show performance of CFR, EpiNow2, or superspreading methods)

README.Rmd Show resolved Hide resolved
README.Rmd Show resolved Hide resolved
README.Rmd Show resolved Hide resolved
README.Rmd Show resolved Hide resolved
README.Rmd Show resolved Hide resolved
vignettes/simulist.Rmd Show resolved Hide resolved
vignettes/simulist.Rmd Show resolved Hide resolved
vignettes/simulist.Rmd Show resolved Hide resolved
vignettes/simulist.Rmd Show resolved Hide resolved
vignettes/age-strat-rates.Rmd Show resolved Hide resolved
Copy link
Member

@Bisaloo Bisaloo left a comment

Choose a reason for hiding this comment

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

Thanks, this looks in a good shape for a release very early next year. I like the current interface.

I have left my comments inline but here is a summary of the main ones:

  • I'm still unsure about passing epidist objects directly rather than functions
  • I'm proposing a different internal package structure for the next version. This would be an internal refactoring so it doesn't need to delay the first release

tests/testthat/setup-options.R Show resolved Hide resolved
R/add_cols.R Show resolved Hide resolved
R/add_cols.R Show resolved Hide resolved
R/add_cols.R Show resolved Hide resolved
R/add_cols.R Show resolved Hide resolved
R/sim_linelist.R Show resolved Hide resolved
R/sim_linelist.R Show resolved Hide resolved
R/sim_linelist.R Show resolved Hide resolved
R/sim_contacts_tbl.R Show resolved Hide resolved
R/sim_utils.R Show resolved Hide resolved
Copy link
Contributor

@CarmenTamayo CarmenTamayo left a comment

Choose a reason for hiding this comment

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

I've tested the functions as they appear on the vignettes and everything works well, I've left some comments, mostly related to changes that could be made to facilitate the understanding of the contents by a first time reader, but overall it looks great and it's a well rounded package, I like how you've solved the issue of simulating both the cases and the contacts for the same outbreak in a way that is so intuitive for users

README.Rmd Show resolved Hide resolved
README.Rmd Show resolved Hide resolved
head(contacts)
```

If both the line list and contacts table are required, they can be jointly simulated using the `sim_outbreak()` function. This uses the same inputs as `sim_linelist()` and `sim_contacts()` to produce a line list and contacts table of the same outbreak (the arguments also have the same default settings as the other functions).
Copy link
Contributor

Choose a reason for hiding this comment

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

This is great 😊

Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe also worth adding when/why a user might want to simulate only contacts or contacts as part of the same outbreak with sim_outbreak?

Copy link
Member Author

Choose a reason for hiding this comment

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

Maybe also worth adding when/why a user might want to simulate only contacts or contacts as part of the same outbreak with sim_outbreak?

Thanks for the comment, I like the idea, but I'm unable to think of a use case/case study that would fit, other than something trivial, e.g. teaching, etc. Could you provide an example of when a user might want each type of dataset?

R/sim_linelist.R Show resolved Hide resolved
vignettes/age-strat-rates.Rmd Show resolved Hide resolved
vignettes/age-struct-pop.Rmd Show resolved Hide resolved
vignettes/age-struct-pop.Rmd Show resolved Hide resolved
vignettes/age-struct-pop.Rmd Show resolved Hide resolved
vignettes/age-struct-pop.Rmd Show resolved Hide resolved
vignettes/vis-linelist.Rmd Show resolved Hide resolved
@joshwlambert
Copy link
Member Author

Thank you for all the comments and suggestions. There have been lots of improvements to the package from this full package review. I have made all changes in separate PRs which are linked to at the bottom of this PR.

I will continue working through the release checklist (#32) and then will release the package.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pkg review Full package review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants