sim.bd | R Documentation |
simulating species richness (or population growth) under a uniform, time-homogeneous birth-death process
sim.bd(b=1, d=0, n0=1, times=0:4, seed=0)
b |
per-lineage birth (speciation) rate |
d |
per-lineage death (extinction) rate |
n0 |
number of taxa at starting time zero |
times |
vector of times where extant species are counted |
seed |
random number seed (default is to seed based on the clock) |
This function simulates species diversification under a uniform birth-death process. This differs
from sim.bdtree
in that only the number of species, and not their phylogenetic affinities, are
stored. This function relates to bd.ms
and bd.km
, which are also non-phylogenetic.
a matrix of population size at each time point
RE Glor and LJ Harmon
Yule, GU. 1924. A mathematical theory of evolution based on the conclusions of Dr. J. C. Willis, FRS. Philos. Trans. R. Soc. London Ser. B 213:21-87
bd.ms
; bd.km
pop1 <- sim.bd(b=0.1, d=0, n0=10, times=1:10)
pop2 <- sim.bd(b=0, d=0.1, n0=10, times=1:10)
pop3 <- sim.bd(b=0.1, d=0.1, n0=10, times=1:10)
plot(pop1, type="l", ylim=c(0,max(c(pop1[,"n"], pop2[,"n"], pop3[,"n"]))))
lines(pop2, col="red")
lines(pop3, col="blue")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.