ra_run_strat | R Documentation |
The stratified model uses a different set of parameters for each starta with the intention to account for population heterogeneity. A strata represents different ways of grouping the target population. I.e. estimate the risk for different age groups, regions, or other groups to account for the population heterogeneity.
ra_run_strat(m, tbl = NULL, nsim, full = F, simplify = T)
m |
Model file. If model file provided as a list, must contain named elements for the 'model' and 'stratified' tables. else a data frame containing a mode table can be provided, if this is the case, the argument tbl must include a data.frame that represents the stratified table |
tbl |
Table with parameters per strata, if model provided as named list, this is not required |
nsim |
Number of simulations |
simplify |
Whether or not the output will be simplified. When simplify = T, the function will return a data.frame with the median and 95 quantiles of the results. When simplify = F, the output will return a list of data.frames corresponding to each of the strata in the model |
data frame with mean, and 95
# use one of the example models
m <- quantrra::asf_products
ra_run_strat(m = m$nodes, tbl = m$stratified, nsim = 10e3)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.