The user can specify a gpiper input file and a vector of populations as well as a vector of proportions of populations and a size of sample and this will do all the leg-work do simulations with gsi_sim using either the fixed-Pi or the Pi variants. Currently it only extracts the mixing proportion estimates out of it.
1 2 | gsi.mixtureSims(B, pops.f, props, N, Reps, fixed = TRUE,
base_file_name = "mix_sim_base.txt", repu.f = NULL, samp_unit = "genes")
|
props |
Vector of mixing proprtions parallel to the levels of pops. These are the true mixing proportions that you want to simulate from |
N |
the sample size of each sample you want to simulate. It will be approximate due to rounding. I could fix that eventually, but it is a bit of a hassle at the moment. |
Reps |
Number of simulated samples you want to simulate |
fixed |
Logical. True means use the –fixed-Pi version (so that the exact same number of fish are simulated each time. False means that the origins of the fish in the simulated sample are drawn from the props (by using the –Pi option of gsi_sim)) |
base_file_name |
The name for baseline file that will be created and passed to gsi_sim |
repu.f |
A factor vector that is parallel to the levels of pops.f, each entry giving the reporting unit that that particular level of pops.f belongs to. This is used to aggregate the estimated mixing proportions over reporting groups. If NULL then it doesn't get done. |
samp_unit |
What sampling unit to resample? Corresponds to gsi_sim's –samp_unit option. Allowable values are "genes", "loci", and "multilocus". |
B |
a genetic baseline in |
pops.f |
a factor vector of populations each individual in B shall belong to. levels of the factor should be in the order that these should appear in. pops.f must have length equal to the number of rows of B |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.