Description Usage Arguments Value Examples
A function to generate some synthetic data based on a few parameters.
1 2 3 4 5 6 7 8 9 10 11 12 13 |
nherds |
The total number of herds |
mean_herd_size |
The mean herd size in the population |
n_herd_urg |
The number of different herd risk groups |
herd_dist |
The fraction of herds in each risk group |
herd_samp_frac |
The total sampling fraction at the herd level |
herd_samp_dist |
The fraction of samples to be collected from each herd risk group |
n_animal_urg |
The number of animal level risk groups |
animal_dist |
The fraction of animals within herds that are part of each risk group |
animal_samp_frac |
The total sampling fraction of animals within herds |
animal_samp_dist |
The fraction of samples that are collected from each animal risk group |
seed |
The seed for the random number generator. Default is a random seed |
A data.frame
1 2 3 4 5 6 7 8 | ## Generate the default example data. This will generate a
## data.frame with a herd identifier (ppn), a herd level unit risk
## group identifier (herd_urg), a animal level unit risk group
## identifier (animal_urg), the total number of animals in the unit
## risk group (N_animal_urg) and the number of animals tested in the
## unit risk group (n_animals_urg).
df <- sample_data()
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.