View source: R/heterogeneityTutorial.R
het.population | R Documentation |
Create a sample of individuals with heterogeneous contact rates
het.population(n, beta.mean, beta.var, seed)
n |
Number of individuals in the population |
beta.mean |
Mean contact rate |
beta.var |
Variance of contact rate |
seed |
Seed for random number generation |
Per ?rgamma
, the gamma distribution is parameterized by shape
and scale
parameters. These parameters are related to the mean by
E(X)=shape*scale
and the variance by
Var(X)=shape*scale^2
.
A numeric vector of contact rates, sorted from highest to lowest
Other heterogeneity:
het.hist()
,
het.run()
,
sample_pair()
,
sample_until()
require(ICI3D)
egpop <- het.population(1000, 2, .5)
het.hist(egpop, 2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.