Description Usage Arguments Value Examples
Create a model for simulating health state transitions with a continuous time state transition model (CTSTM).
1 | create_transmod(params, data)
|
params |
A "params_surv" object returned from
|
data |
A data table of class "expanded_hesim_data" returned from
|
An object of class "IndivCtstmTrans" from the hesim package.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 | # Treatment sequences
txseq1 <- txseq(first = "erlotinib",
second = c("osimertinib", "PBDC"),
second_plus = c("PBDC + bevacizumab", "PBDC + bevacizumab"))
txseq2 <- txseq(first = "gefitinib",
second = c("osimertinib", "PBDC"),
second_plus = c("PBDC + bevacizumab", "PBDC + bevacizumab"))
txseqs <- txseq_list(seq1 = txseq1, seq2 = txseq2)
# Patient population
pats <- create_patients(n = 2)
# Model structure
struct <- model_structure(txseqs, dist = "weibull")
tmat <- create_trans_mat(struct)
# Data for state transition model
transmod_data <- create_transmod_data(struct, tmat, pats)
head(transmod_data)
# Parameters for state transition model
transmod_params <- create_transmod_params(n = 2, transmod_data)
print(transmod_params)
# State transition model
transmod <- create_transmod(transmod_params, transmod_data)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.