View source: R/snp.sim.Q_old.R View source: R/snp.sim.Q.R
snp.sim.Q | R Documentation |
Currently under development. Please use the regular snp.sim function to simulate genetic data.
NOT currently in use. Please use the regular snp.sim function to simulate genetic data.
snp.sim.Q(
n.snps = 10000,
n.subs = 1,
snp.root = NULL,
n.snps.assoc = 10,
assoc.prob = 100,
Q = matrix(c(2, 0.75, 0.75, 1, 3, 0.5, 0.25, 3, 3, 0.25, 0.5, 3, 1, 0.75, 0.75, 2),
nrow = 4, byrow = T, dimnames = rep(list(c("0|0", "0|1", "1|0", "1|1")), 2)),
tree = coalescent.tree.sim(100),
n.phen.subs = 15,
phen.loci = NULL,
heatmap = FALSE,
reconstruct = FALSE,
dist.dna.model = "JC69",
grp.min = 0.25,
row.names = NULL,
set = 3,
seed = 1
)
snp.sim.Q(
n.snps = 10000,
n.subs = 1,
snp.root = NULL,
n.snps.assoc = 10,
assoc.prob = 100,
Q = matrix(c(2, 0.75, 0.75, 1, 3, 0.5, 0.25, 3, 3, 0.25, 0.5, 3, 1, 0.75, 0.75, 2),
nrow = 4, byrow = T, dimnames = rep(list(c("0|0", "0|1", "1|0", "1|1")), 2)),
tree = coalescent.tree.sim(100),
n.phen.subs = 15,
phen.loci = NULL,
heatmap = FALSE,
reconstruct = FALSE,
dist.dna.model = "JC69",
grp.min = 0.25,
row.names = NULL,
set = 3,
seed = 1
)
n.snps |
An integer specifying the number of snps columns to be simulated. |
tree |
A |
heatmap |
A logical indicating whether to produce a heatmap of the genetic distance between the simulated genomes of the n.ind individuals. |
reconstruct |
Either a logical indicating whether to attempt to reconstruct a phylogenetic tree using the simulated genetic data, or one of c("UPGMA", "nj", "ml") to specify that tree reconstruction is desired by one of these three methods (Unweighted Pair Group Method with Arithmetic Mean, Neighbour-Joining, Maximum-Likelihood). |
dist.dna.model |
A character string specifying the type of model to use in reconstructing the phylogenetic tree for
calculating the genetic distance between individual genomes, only used if |
grp.min |
(Not yet (re-)implemented in this function.) An optional number between 0.1 and 0.9 to control the proportional size of the smaller phenotypic group. |
row.names |
An optional vector containing row names for the individuals to be simulated. |
seed |
An optional integer to control the pseudo-randomisation process and allow for identical repeat runs of the function;
else |
phen.reconstruction |
Either a character string specifying |
s |
If |
af |
If |
plot |
A logical indicating whether to generate a plot of the phylogenetic tree ( |
Caitlin Collins caitiecollins@gmail.com
## Example ##
## Example ##
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.