
Last chance! 50% off unlimited learning
Sale ends in
lineage
generates a complete tree including
the species that go extinct; rbdtree
generates a tree with only
the species until present; drop.fossil
is a utility function to
remove the extinct species.rlineage(birth, death, Tmax = 50, BIRTH = NULL,
DEATH = NULL, eps = 1e-6)
rbdtree(birth, death, Tmax = 50, BIRTH = NULL,
DEATH = NULL, eps = 1e-6)
drop.fossil(phy, tol = 1e-8)
"phylo"
.BIRTH
and/or
DEATH
may be used of the primitives of birth
and
death
are known. In these functions time is the formal argument
and must be named t
.Paradis, E. (2011) Time-dependent speciation and extinction from phylogenies: a least squares approach. Evolution, 65, 661--672.
yule
, yule.time
, birthdeath
,
rtree
, stree
plot(rlineage(0.1, 0)) # Yule process with lambda = 0.1
plot(rlineage(0.1, 0.05)) # simple birth-death process
b <- function(t) 1/(1 + exp(0.2*t - 1)) # logistic
layout(matrix(0:3, 2, byrow = TRUE))
curve(b, 0, 50, xlab = "Time", ylab = "")
mu <- 0.07
segments(0, mu, 50, mu, lty = 2)
legend("topright", c(expression(lambda), expression(mu)),
lty = 1:2, bty = "n")
plot(rlineage(b, mu), show.tip.label = FALSE)
title("Simulated with 'rlineage'")
plot(rbdtree(b, mu), show.tip.label = FALSE)
title("Simulated with 'rbdtree'")
Run the code above in your browser using DataLab