Generate a virtual population
Generate a virtual population
httkpop_generate( method, nsamp = NULL, gendernum = NULL, agelim_years = NULL, agelim_months = NULL, weight_category = c("Underweight", "Normal", "Overweight", "Obese"), gfr_category = c("Normal", "Kidney Disease", "Kidney Failure"), reths = c("Mexican American", "Other Hispanic", "Non-Hispanic White", "Non-Hispanic Black", "Other") )
method |
The population-generation method to use. Either "virtual individuals" or "direct resampling." Short names may be used: "d" or "dr" for "direct resampling", and "v" or "vi" for "virtual individuals". |
nsamp |
The desired number of individuals in the virtual population.
|
gendernum |
Optional: A named list giving the numbers of male and
female individuals to include in the population, e.g. |
agelim_years |
Optional: A two-element numeric vector giving the
minimum and maximum ages (in years) to include in the population. Default is
c(0,79). If only a single value is provided, both minimum and maximum ages
will be set to that value; e.g. |
agelim_months |
Optional: A two-element numeric vector giving the
minimum and maximum ages (in months) to include in the population. Default
is c(0, 959), equivalent to the default |
weight_category |
Optional: The weight categories to include in the
population. Default is |
gfr_category |
The kidney function categories to include in the
population. Default is |
reths |
Optional: a character vector giving the races/ethnicities to
include in the population. Default is |
A data.table where each row represents an individual, and each column represents a demographic, anthropometric, or physiological parameter.
Caroline Ring
Ring, Caroline L., et al. "Identifying populations sensitive to environmental chemicals by simulating toxicokinetic variability." Environment International 106 (2017): 105-118
#Simply generate a virtual population of 100 individuals, #using the direct-resampling method set.seed(42) httkpop_generate(method='direct resampling', nsamp=100) #Generate a population using the virtual-individuals method, #including 80 females and 20 males, #including only ages 20-65, #including only Mexican American and #Non-Hispanic Black individuals, #including only non-obese individuals httkpop_generate(method = 'virtual individuals', gendernum=list(Female=80, Male=20), agelim_years=c(20,65), reths=c('Mexican American', 'Non-Hispanic Black'), weight_category=c('Underweight', 'Normal', 'Overweight'))
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.