Description Usage Arguments Details Value Examples
View source: R/simulate_data_fnxs.R
Simulate data under additive model.
1 | sim.add.data(n.muts, addcoes, sigma, w.wt, geno.matrix)
|
n.muts |
Number of mutations. |
addcoes |
Vector of additive effect for each mutation |
sigma |
Noise to add to expectations |
w.wt |
Fitness of the wildtype |
geno.matrix |
Specifies which genotypes are simulated. |
Function takes additive effects (addcoes
) and generates the expected
fitness values for each genotype. This set of expected values is returned as fit.matrix.exp
.
Then it adds normal error to them to produce the "observed" data (fit.matrix
).
List:
[[1]] fit.matrix
is matrix with (simulated) observed data
[[2]] fit.matrix.exp
is same matrix without error
1 2 3 | addcoes <- rep(0.3, 3)
geno.matrix <- generate.geno.matrix(3)
sim.add.data(3,addcoes,0.1,1,geno.matrix)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.