View source: R/make_population.R
make_population | R Documentation |
This function takes a frequencies()
object and
returns a data.frame
with the appropriate
stratum and loci derived randomly.
make_population(x, N = 20, F = 0)
x |
A |
N |
The number of individuals to create (default = 20). This is a 'per-stratum' estimate so if you have K strata the result will be K*N individuals. |
F |
The inbreeding index (Fis). |
A data.frame
with individuals, loci, and potentially strata
Rodney J. Dyer rjdyer@vcu.edu
freqs <- c(0.55, 0.30, 0.15, 0.34, 0.34, 0.32)
loci <- c(rep("TPI",3), rep("PGM",3))
alleles <- c(LETTERS[1:3],LETTERS[8:10])
f <- data.frame(Locus=loci, Allele=alleles, Frequency=freqs)
make_population(f,N=20)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.