-
Notifications
You must be signed in to change notification settings - Fork 16
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
Custom carrying capacity is set as a relative scaler, not absolute value #272
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All looks good to me! I wonder whether it would be good to reference and explain how the initial carrying capacity gets generated at the start of the vignette. i.e., you don't explicitly set carrying capacity parameter, but the carrying capacity gets generated in set_equilibrium, to match the EIR and population size, and this is what the scalers are relative to. (Assuming I've understood this correctly!)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Really nice! I had one suggestion about wording in the markdown but otherwise looks great!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we're sure we'll never use absolute carrying capacity here, then this is cleaner and feel free to merge.
If not, then it would probably be best to copy set_carrying_capacity
to set_relative_carrying_capacity
which sets the appropriate parameters.
Thanks for this!
Also, to pass the merge checks please run |
Thanks all! 🙏😎 @giovannic - I've left |
Our previous implementation of a flexible carrying capacity that the user could set using
set_ carrying_capacity()
asked for absolute values of the carrying capacity at time change points to be specified. This in turn required the user to know the baseline carrying capacity (k0
), which requiredset_equilibrium()
to be called. This was problematic for downstream processes such as calibration. When calibrating we want to be able to re-set the equilibrium (by re-callingset_equilibrium()
) whilst retaining the impact of any previously set interventions. Asset_ carrying_capacity()
previously depended onk0
this broke the work flow.To address this the user now specifies the carrying capacity changes as scalers which rescale
k0
and are therefore indepent of the aboslute value ofk0
. This change retains all previous options:The new method also is species specific:
The new method also can be combined with seasonal profiles: