setRootAge: Place a Non-Ultrametric Tree of Fossil Taxa on Absolute Time

View source: R/setRootAge.R

setRootAgeR Documentation

Place a Non-Ultrametric Tree of Fossil Taxa on Absolute Time

Description

This function uses a table of fixed dates for operational-taxon-units (tip taxa) to calculate the absolute age of the root divergence for a tree with branch lengths, and then appends this root age to the tree as a $root.time element, and then outputs the tree. Function setRootAges is a wrapper for setRootAge for use with multiple trees in a object of class multiPhylo. This function was mainly written for dealing with trees of extinct taxa dated in units of absolute time from Bayesian analyses, such as with MrBayes, with trees scaled to time units by functions such as obtainDatedPosteriorTreesMrB.

Usage

setRootAge(tree, fixedAges = NULL)

setRootAges(trees, fixedAges = NULL)

Arguments

tree

A phylogeny with branch lengths of class phylo.

fixedAges

A table of fixed ages for tip taxa, generally as a dataframe where the first column is of type character, and the second column is of type numeric. Such a table is automatically generated as an attribute of the output from obtainDatedPosteriorTreesMrB, when argument getFixedTimes = TRUE.

trees

A list of class multiPhylo consisting of multiple phylogenetic trees with branch lengths.

Details

Trees of fossil taxa come with one issue rarely encountered by those dealing with molecular phylogenies: the absolute timing of when tips and divergences is not certain. With the vast majority of molecular phylogenies, it can be assumed the youngest tips occur at time 0 – in other words , the modern. This knowledge gives the tree an 'anchor' for fixing the absolute timing of events. Many programs and other software designed for depicting and analyzing phylogenetic hypotheses assumes such an apparent absolute time-scale (in R and elsewhere). A phylogenetic analysis of Paleozoic brachiopods that include no extant members has no such anchor at time = 0, and such a default assumption in available software can be misleading. The $root.time protocol is intended to grant this absolute time-scale to a dated tree of fossil taxa, and is appended by most of the dating functions in package paleotree. However, trees dated by other approaches, such as via tip-dating in programs such as MrBayes and BEAST, will not have $root.time elements when read into R.

Value

The input tree is output, with a new $root.time element.

Author(s)

David W. Bapst

See Also

setRootAges is designed to work by default with trees on relative time-scales dated by obtainDatedPosteriorTreesMrB, particularly when the argument with getFixedTimes = TRUE, which is used to obtain fixed tip ages for anchoring the tree against an absolute time-scale. The functions described here will be applied automatically with obtainDatedPosteriorTreesMrB if argument getRootAges = TRUE.

Examples


set.seed(444)
tree <- rtree(10)
tipAges <- cbind(c("t1","t2"), c(15,10))

absTimeTree <- setRootAge(tree = tree,tipAges)

plot(absTimeTree)
axisPhylo()


paleotree documentation built on Aug. 22, 2022, 9:09 a.m.