hesim_data {hesim} | R Documentation |
Data for health economic simulation modeling
Description
A list of tables required for health economic simulation modeling. This object is used to setup models by defining the treatment strategies, target population, and model structure.
Usage
hesim_data(strategies, patients, states = NULL, transitions = NULL)
Arguments
strategies |
A table of treatment strategies. Must contain the column
|
patients |
A table of patients. Must contain the column |
states |
A table of health states. Must contain the column
|
transitions |
A table of health state transitions. Must contain the column
|
Value
Returns an object of class hesim_data
, which is a list of data tables for
health economic simulation modeling.
Note
Each table must either be a data.frame
or data.table
. All ID variables
within each table must be numeric vectors of integers and should be of the form
1,2,...N where N is the number of unique values of the ID variable.
See Also
expand.hesim_data()
, get_labels()
Examples
strategies <- data.frame(strategy_id = c(1, 2))
patients <- data.frame(patient_id = seq(1, 3), age = c(65, 50, 75),
gender = c("Female", "Female", "Male"))
states <- data.frame(state_id = seq(1, 3),
state_var = c(2, 1, 9))
hesim_dat <- hesim_data(strategies = strategies,
patients = patients,
states = states)