epiverse-trace / epichains

Methods for simulating and analysing the sizes and lengths of infectious disease transmission chains from branching process models
https://epiverse-trace.github.io/epichains/
Other
6 stars 2 forks source link

Multiple issues: make `offspring_dist` accept a function #188

Closed sbfnk closed 8 months ago

sbfnk commented 9 months ago

This PR changes the offspring_dist argument of likelihood and simulate_chains to expect a function instead of a character string.

Yes. No version has been released yet so not going through a deprecation cycle.

Doing this necessitated two further changes:

Closes #25 Closes #167

codecov-commenter commented 9 months ago

Codecov Report

Attention: 3 lines in your changes are missing coverage. Please review.

Comparison is base (d3e8d85) 99.45% compared to head (6bf6e90) 98.90%.

:exclamation: Current head 6bf6e90 differs from pull request most recent head e2df869. Consider uploading reports for the commit e2df869 to get more accurate results

Files Patch % Lines
R/borel.r 78.57% 3 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #188 +/- ## ========================================== - Coverage 99.45% 98.90% -0.55% ========================================== Files 8 8 Lines 546 548 +2 ========================================== - Hits 543 542 -1 - Misses 3 6 +3 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

sbfnk commented 9 months ago

Might need updating in line with #190

jamesmbaazam commented 9 months ago

LGTM. Thanks for the change. I believe it resolves #50 as well.

jamesmbaazam commented 9 months ago

Might need updating in line with #190

Oh, I just merged that. You can rebase on main.

sbfnk commented 9 months ago

LGTM. Thanks for the change. I believe it resolves #50 as well.

3 in one go!

jamesmbaazam commented 9 months ago

Please feel free to rebase and merge.

jamesmbaazam commented 9 months ago

@sbfnk Do you mind me merging this?

jamesmbaazam commented 9 months ago

The issue number in the title undersells the change as it resolves 3 related issues, so it might be better to either add the others or remove the current one.

sbfnk commented 9 months ago

@sbfnk Do you mind me merging this?

I think @Bisaloo was still going to kindly review at some point in the near future.

sbfnk commented 8 months ago

Not immediately clear to me why the R CMD CHECK action fails as it seems to run the previous version of code in the examples.

Bisaloo commented 8 months ago

The branch needs to be rebased and the following examples updated:

https://github.com/epiverse-trace/epichains/blob/d3e8d850bf1627aed4259af1dd7edf18beb91e41/R/epichains.R#L433-L443

https://github.com/epiverse-trace/epichains/blob/d3e8d850bf1627aed4259af1dd7edf18beb91e41/R/epichains.R#L455-L464

https://github.com/epiverse-trace/epichains/blob/d3e8d850bf1627aed4259af1dd7edf18beb91e41/R/epichains.R#L487-L505

sbfnk commented 8 months ago

The branch needs to be rebased and the following examples updated:

Thanks but these are no longer present in 9953900 which failed the checks. I'm confused.

sbfnk commented 8 months ago

Does the action not check out a force pushed version?

Bisaloo commented 8 months ago

Thanks but these are no longer present in https://github.com/epiverse-trace/epichains/commit/99539007407585f55c433e13959b2c780d651ae1 which failed the checks. I'm confused.

They are present in the merge commit since they come from https://github.com/epiverse-trace/epichains/commit/712c2661ca900fba24e4607838f337e0d46e1695 which is not included in your base branch. If you rebase your branch on top of the latest main, you should see them.

sbfnk commented 8 months ago

Thanks but these are no longer present in 9953900 which failed the checks. I'm confused.

They are present in the merge commit since they come from 712c266 which is not included in your base branch. If you rebase your branch on top of the latest main, you should see them.

Thanks - I had no idea action were checking merge commits.