aphp / heemod

Markov Models for Health Economic Evaluations
https://aphp.github.io/heemod/
GNU General Public License v3.0
11 stars 1 forks source link

Defining the state_time_limit argument of the function run_model() #8

Closed TwT9807 closed 1 year ago

TwT9807 commented 1 year ago

I am not sure why state_time_limit should be defined and how to define it properly. Does it mean that the model will only use state_time within the limit? What about the state_time used in ifelse(), such as ifelse(state_time > 6, cost1, cost2)? What happens if I set the limit to 6? Thanks

KZARCA commented 1 year ago

When you use state_time in your model, heemod creates a new transitory state. state_time_limit limits the state expansion aka tunnel states, which is very computationally expansive.

state_time_limit can be specified in 3 different ways:

  1. As a single value: the limit is applied to all states in all strategies.
  2. As a named vector (where names are state names): the limits are applied to the given state names, for all strategies.
  3. As a named list of named vectors: the limits are applied to the given state names for the given strategies.
TwT9807 commented 1 year ago

Thanks. I get it!!