mac-theobio / McMasterPandemic

SEIR+ model
GNU General Public License v3.0
20 stars 5 forks source link

Warning when symbols provided in params and/or state vectors are not used in `flexmodel` model definition #228

Open papsti opened 2 years ago

papsti commented 2 years ago

Currently an error gets thrown when the user tries to run a model where the flexmodel definition (handled through functions like add_rate(), etc.) utilizes symbols that have not been passed through the params or state vectors. It would be great if a warning for the converse case existed, i.e., when a user provides a symbol via the params or state vectors that isn't actually used in the model definition.

I can imagine a case where a user puts a parameter symbol in the params list intending to build a mechanism using it, but then forgets to add it to the model definition, and runs the model thinking that mechanism has actually been implemented. The warning I suggest would help prevent this issue.