Learn R Programming

phytools (version 2.5-2)

plotBranchbyTrait: Plot branch colors by a quantitative trait or value

Description

Function plots a tree with branches colored by the value for a quantitative trait or probability, by various methods.

Usage

plotBranchbyTrait(tree, x, mode=c("edges","tips","nodes"), palette="rainbow", 
   legend=TRUE, xlims=NULL, ...)

Arguments

Value

Plots a phylogeny.

Details

Unlike most other tree plotting functions in phytools, this function calls plot.phylo (not plotSimmap) internally.

Note that if prompt=TRUE, the function will prompt for the position of the legend.

References

Revell, L. J. (2024) phytools 2.0: an updated R ecosystem for phylogenetic comparative methods (and other things). PeerJ, 12, e16505.