Reads in the app state from yaml files.
Value
list with the following elements
isgood: Boolean indicating the exit status of the function.
msgs: Messages to be passed back to the user.
yaml_list: Lists with preload components.
Examples
# \donttest{
sess_res = CTS_test_mksession()
#> → ASM: including file
#> → ASM: source: file.path(system.file(package="onbrand"), "templates", "report.docx")
#> → ASM: dest: file.path("config","report.docx")
#> → ASM: including file
#> → ASM: source: file.path(system.file(package="onbrand"), "templates", "report.pptx")
#> → ASM: dest: file.path("config","report.pptx")
#> → ASM: including file
#> → ASM: source: file.path(system.file(package="onbrand"), "templates", "report.yaml")
#> → ASM: dest: file.path("config","report.yaml")
#> → ASM: State initialized
#> → ASM: setting word placeholders:
#> → ASM: -> setting docx ph: HEADERLEFT = left header
#> → ASM: -> setting docx ph: HEADERRIGHT = right header
#> → ASM: -> setting docx ph: FOOTERLEFT = left footer
#> → ASM: module isgood: TRUE
#> → MB: including file
#> → MB: source: file.path(system.file(package="onbrand"), "templates", "report.docx")
#> → MB: dest: file.path("config","report.docx")
#> → MB: including file
#> → MB: source: file.path(system.file(package="onbrand"), "templates", "report.pptx")
#> → MB: dest: file.path("config","report.pptx")
#> → MB: including file
#> → MB: source: file.path(system.file(package="onbrand"), "templates", "report.yaml")
#> → MB: dest: file.path("config","report.yaml")
#> ! MB: User-defined model: /Users/jmh/projects/ruminate/github/ruminate/docs/reference/user_model.R not found (skipping)
#> ! MB: User-defined model: /Users/jmh/projects/ruminate/github/ruminate/docs/reference/user_model.ctl not found (skipping)
#> → MB: module checksum updated:f7de2055542d3ff1b085fafc2d30a1f8
#> → MB: State initialized
#> → MB: loading model idx: 1
#>
#>
#> ℹ parameter labels from comments are typically ignored in non-interactive mode
#> ℹ Need to run with the source intact to parse comments
#> → MB: model checksum updated: 41fe9ee621c1b4474e42c96447d93ca3
#> → MB: module checksum updated:e5d202dda031b0b5d1e27bee2fc26178
#>
#>
#> ℹ parameter labels from comments are typically ignored in non-interactive mode
#> ℹ Need to run with the source intact to parse comments
#> → MB: model checksum updated: ae34d319bf07de5bdc7bb3a297895044
#> → MB: module checksum updated:2c87e4d6bbaf13cd6e28f913a91d480b
#> → MB: -> setting name: One compartment model
#> → MB: -> setting time scale: hours
#> → MB: -> setting base from: user
#> → MB: -> setting catalog selection:
#> → MB: -> setting base model id: manual
#> → MB: -> setting base model name: manual
#> → MB: model checksum updated: 4d0aabce45397027ce3f05b40a0e0c0e
#> → MB: module checksum updated:1a15599f0cecb560c1e3ff74630e991e
#> → MB: added element idx: 1
#> → MB: loading model idx: 2
#>
#>
#> ℹ parameter labels from comments are typically ignored in non-interactive mode
#> ℹ Need to run with the source intact to parse comments
#> → MB: model checksum updated: f761aef1f56e7b143782e761168f508a
#> → MB: module checksum updated:7abcb99edc1a62bc9b06b8887b247a17
#> → MB: -> setting name: PK Biomarker
#> → MB: -> setting time scale: days
#> → MB: -> setting base from: user
#> → MB: -> setting catalog selection:
#> → MB: -> setting base model id: manual
#> → MB: -> setting base model name: manual
#> → MB: model checksum updated: 89d3b43e7e2dccfce5f9a5c939c43e60
#> → MB: module checksum updated:3e37a6ca9ba495ffbc0570b757194e09
#> → MB: added element idx: 2
#> → MB: module isgood: TRUE
#> → CTS: including file
#> → CTS: source: file.path(system.file(package="onbrand"), "templates", "report.docx")
#> → CTS: dest: file.path("config","report.docx")
#> → CTS: including file
#> → CTS: source: file.path(system.file(package="onbrand"), "templates", "report.pptx")
#> → CTS: dest: file.path("config","report.pptx")
#> → CTS: including file
#> → CTS: source: file.path(system.file(package="onbrand"), "templates", "report.yaml")
#> → CTS: dest: file.path("config","report.yaml")
#> → CTS: source model change detected
#> → CTS: > covariates reset
#> → CTS: cohort checksum updated: 6048854e9749d49a6a32f58e8589c14b
#> → CTS: module checksum updated: 74445b3547e3d69f02e466dcb50b8dc7
#> → CTS: State initialized
#> → CTS: loading element idx: 1
#> → CTS: setting cohort name: Single dose
#> → CTS: setting model source: MB_obj_1_rx
#> → CTS: setting trial options:
#> → CTS: - nsub: 3
#> → CTS: - visit_times: 0
#> → CTS: - trial_end: 100
#> → CTS: - fpage: 1
#> → CTS: - dvcols: Cc
#> → CTS: - time_scale:
#> → CTS: - tc_dim: d2x4
#> → CTS: - evplot: 1
#> → CTS: - cts_config_atol: 1e-8
#> → CTS: - cts_config_rtol: 1e-6
#> → CTS: - cts_config_sigdig: NULL
#> → CTS: - cts_config_seed: 5446
#> → CTS: - cts_config_nsteps: 5
#> → CTS: - cts_config_preamble:
#> → CTS: cohort checksum updated: 8134dd817da7f1823ec6a12efb2f0a6c
#> → CTS: module checksum updated: ed5d1ef0af901ff6159b21c5bc128861
#> → CTS: adding rule: first_dose
#> → CTS: add rule success
#> → CTS: rule added
#> → CTS: cohort checksum updated: d0da1cded0576efe72eb3fa15434afb3
#> → CTS: module checksum updated: ff203e3b7a3c15df80d4b15160258906
#>
#>
#> using C compiler: ‘Apple clang version 16.0.0 (clang-1600.0.26.6)’
#> using SDK: ‘’
#>
#>
#> using C compiler: ‘Apple clang version 16.0.0 (clang-1600.0.26.6)’
#> using SDK: ‘’
#> Warning: multi-subject simulation without without 'omega'
#>
#>
#> Warning: multi-subject simulation without without 'omega'
#> → CTS: simulation complete
#> → CTS: plot complete
#> → CTS: cohort checksum updated: 6867c125aaa79e44beb195476085c303
#> → CTS: module checksum updated: 8090b1da093c3586c68202af4d2b175c
#> → CTS: added element idx: 1
#> → CTS: module isgood: TRUE
#> → # preload_complete is good: TRUE ------------------------------------------
state = sess_res$state
res = CTS_mk_preload(state)
#> → CTS: saving element (1) Single dose
#> → CTS: -> rule dose
#> → CTS: mk_preload isgood: TRUE
# }