Learn R Programming

phangorn (version 1.5-0)

bootstrap.pml: Bootstrap

Description

bootstrap.pml performs (non-parametric) bootstrap analysis and bootstrap.phyDat produces a list of bootstrapped data sets. plotBS plots a phylogenetic tree with the with the bootstrap values assigned to the (internal) edges.

Usage

bootstrap.pml(x, bs = 100, trees = TRUE, multicore=FALSE, ...)
bootstrap.phyDat(x, FUN, bs = 100, multicore=FALSE, ...)
plotBS(tree, BStrees, type="unrooted", bs.col="black", bs.adj=NULL, ...)

Arguments

x
an object of class pml or phyDat.
bs
number of bootstrap samples.
trees
return trees only (default) or whole pml objects.
multicore
logical, if TRUE analysis is performed in parallel (see details).
...
further parameters used by optim.pml or plot.phylo.
FUN
the function to estimate the trees.
tree
The tree on which edges the bootstrap values are plotted.
BStrees
a list of trees (object of class "multiPhylo").
type
the type of tree to plot, so far "cladogram", "phylogram" and "unrooted" are supprted.
bs.col
color of bootstrap support labels.
bs.adj
one or two numeric values specifying the horizontal and vertical justification of the bootstrap labels.

Value

  • returns an object of class multi.phylo or a list where each element is an object of class pml.

Details

It is possible that the bootstrap is performed in parallel, with help of the multicore package. Unfortunately the multicore package does not work under windows or with GUI interfaces ("aqua" on a mac). However it will speed up nicely from the command line ("X11").

References

Felsenstein J. (1985) Confidence limits on phylogenies. An approach using the bootstrap. Evolution 39, 783--791

Penny D. and Hendy M.D. (1985) Testing methods evolutionary tree construction. Cladistics 1, 266--278

Penny D. and Hendy M.D. (1986) Estimating the reliabbility of evolutionary trees. Molecular Biology and Evolution 3, 403--417

See Also

optim.pml, pml, plot.phylo

Examples

Run this code
data(Laurasiatherian)
dm <- dist.logDet(Laurasiatherian)
tree <- NJ(dm)
fit=pml(tree,Laurasiatherian)
fit = optim.pml(fit,TRUE)

set.seed(1)
bs <- bootstrap.pml(fit, bs=100, optNni=TRUE)
plotBS(fit$tree,bs)

Run the code above in your browser using DataLab