getExtant: Returns a list of the extant or extinct lineages in a tree...

View source: R/utilities.R

getExtantR Documentation

Returns a list of the extant or extinct lineages in a tree containing non-contemporaneous tips

Description

Computes the set of extant or extinct tips from a phylogenetic tree.

Usage

getExtant(tree, tol=1e-8)
getExtinct(tree, tol=1e-8)

Arguments

tree

a phylogeny stored as an object of class "phylo" with some tips that are non-contemporaneous (i.e., end before the present).

tol

a tolerance value to account for numerical imprecision.

Details

The function getExtant takes a tree as input and returns a vector containing the names of all the tips that have a height above the root that is equal (to a degree of numerical precision determined by tol) to the height of the highest tip. These tips are presumed to be "extant."

getExtinct returns the complement.

Value

A vector with the tip names of extant or extinct species in the tree.

Author(s)

Liam Revell liam.revell@umb.edu

References

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

See Also

nodeHeights


phytools documentation built on June 22, 2024, 10:39 a.m.