Simulate treatment by subgroups - parallelized Given the proportions of treatments by subgroups, simulate treatment
1 2 | parsim_treatment_by_subgroup(treat_chars, stage_subgroup_rows, thisprop,
pop_size, nsim, ncores = 4)
|
treat_chars |
Data frame indicating stage-subgroup #s in the SSno variable and stage-subgroup-treatment #s in txSSno, and prop_* columns where * is the trial name. |
stage_subgroup_rows |
Matrix indicating, for each person-sim, which stage-subgroup they are in (using the SSid from treat_chars) |
thisprop |
Character indicating the prop_* column name from which to take treatment proportions |
pop_size |
Population size |
nsim |
Number of sims |
ncores |
Number of cores |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.