The input list can be nested in arbitrary levels, as long as the names at the last level matches those used in the corresponding Stan model.
Examples
fp = system.file("cases", "treatment_dynamics", "1-simplified-normal-model", "simulation.R", package="stom")
source(fp)
d = sim_data()
str(d$params)
#> List of 7
#> $ B_TE : num [1:3] 0.5 1 2
#> $ B_ED : num 1.5
#> $ B_AE : num 1
#> $ B_AD : num 0.8
#> $ E : num [1:30, 1:4] -0.103 -1.087 -3.829 -2.032 -2.71 ...
#> $ I : num [1:20] -3 -2.68 -2.37 -2.05 -1.74 ...
#> $ kappa: num [1:5] -2.4 -1.1 0 1.1 2.4
get_sim_param_info(d$params)
#> $B_TE
#> $B_TE$cls
#> [1] "vector"
#>
#> $B_TE$dim
#> [1] 3
#>
#>
#> $B_ED
#> $B_ED$cls
#> [1] "vector"
#>
#> $B_ED$dim
#> [1] 1
#>
#>
#> $B_AE
#> $B_AE$cls
#> [1] "vector"
#>
#> $B_AE$dim
#> [1] 1
#>
#>
#> $B_AD
#> $B_AD$cls
#> [1] "vector"
#>
#> $B_AD$dim
#> [1] 1
#>
#>
#> $E
#> $E$cls
#> [1] "matrix"
#>
#> $E$dim
#> [1] 30 4
#>
#>
#> $I
#> $I$cls
#> [1] "vector"
#>
#> $I$dim
#> [1] 20
#>
#>
#> $kappa
#> $kappa$cls
#> [1] "vector"
#>
#> $kappa$dim
#> [1] 5
#>
#>