tseyanglim / VST

Vensim Script Tools for improving workflow in Vensim
GNU General Public License v3.0
4 stars 1 forks source link

Is function for getting parameter value from outside voc file appropriate for widgets? #7

Open hyunjimoon opened 1 year ago

hyunjimoon commented 1 year ago

The need for getting the parameter values outside voc file is needed for sensitivity test. This is because, we wish to do sensitivity test on not only estimated parameter (e.g. Variant Impact on Immunity Loss Time[Vrnts], Variant Accuity Multiplier[Vrnts], Variant Transmission Multiplier[Vrnts], Immunity Loss Time[VS], Weight on Reported Probability of Infection[Rgn]), but also assumed parameter (e.g. Variant Intro Start Time3, Extra Vaccine Impact on Responsiveness[VS]).

To add this functionality (or is it already implemented?), would widget be the best place? @tseyanglim could you recommend some template I can refer to?

tseyanglim commented 1 year ago

There's a function get_value already implemented in VST (in the VST-Text notebook) that lets you extract the value for a given named parameter from a text-readable file (including mdl files, but also e.g. cin or out). Is that what you need?

(Note that it may not work with subscripted variables depending on how they're formulated - if with a unique subscripted equation, should work, but if with short-form subscripted equations, probably won't)