genSeq {phytools} | R Documentation |
Simulates DNA sequence on tree
under the specified model. Uses sim.history
internally.
genSeq(tree, l=1000, Q=NULL, rate=1, format="DNAbin", ...)
tree |
object of class |
l |
length of desired sequences. |
Q |
transition matrix for the simulation. Row and column names |
rate |
multiplier for |
format |
format of the output object. Can be |
... |
optional arguments. |
An object of class "DNAbin"
or "phyDat"
, or a matrix of nucleotides.
Liam Revell liam.revell@umb.edu
Revell, L. J. (2012) phytools: An R package for phylogenetic comparative biology (and other things). Methods Ecol. Evol., 3, 217-223.
## simulate gamma rate heterogeneity tree<-pbtree(n=26,tip.label=LETTERS) gg<-rgamma(n=100,shape=0.25,rate=0.25) X<-genSeq(tree,l=100,rate=gg)