Description Usage Arguments Value Author(s) Examples
Function used to initialize multilocus simulations.
1 2 3 4 5 6 7 8 | initialize.multilocus(allele_vec,
r,
mu=rep(0,length(allele_vec)),
n,
z,
kappa0,
init.state="fixed",
sexuality=NULL)
|
allele_vec |
Vector giving the number of alleles at each locus. |
r |
Recombination rate. A single value between 0 and 0.5. For more than two loci, recombination rate must be set to 0.5. |
mu |
Vector giving the mutation rate for each locus, i.e. the probability that an allele mutate to a different allele. |
n |
Number of demes. |
z |
Number of age classes. |
kappa0 |
Initial number of individuals per deme. This is used to assign individuals to genotype and age-classes in each deme according to the criterion defined in |
init.state |
String defining the genetic composition of the initial population. If |
sexuality |
One of |
A list with the following items:
r |
The recombination rate input by the user |
mu |
The vector of mutation rates input by the user |
m |
The number of multilocus genotypes |
n |
The number of demes input by the user |
z |
The number of age-classes input by the user |
kappa0 |
The initial number of individuals per deme given by the user |
index_matr |
The index of the multilocus genotypes given by the function |
meiosis_matrix |
A matrix giving the probabilities of producing multilocus gametes (rows) for each multilocus genotype (columns) |
mat_geno_to_index_mapping |
A square matrix giving the genotype index for each combination of female (rows) and male (columns) multilocus gametes |
N1 |
The initial composition of the population as a 3D array giving the number of individuals of each genotype (first dimension) in each deme (second dimension) in each age-class (third dimension) |
Marco Andrello
1 2 3 4 5 6 7 8 9 10 11 12 | ## Not run:
allele_vec <- c(2,2)
init.par <- initialize.multilocus(allele_vec=allele_vec,
r=0.5,
mu=c(0.01,0.01),
n=3,
z=1,
kappa0=100,
sexuality="monoecious")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.