average_tr_tips: Average the heights of (non-fossil) tips to make...

Description Usage Arguments Details Value Note Author(s) References See Also Examples

View source: R/BioGeoBEARS_generics_v1.R

Description

When you have a digitized tree, or other slightly uneven source tree, average the tips to get them all to line up at 0 my before present. This makes an ultrametric tree if and only if there are no fossil tips in the tree.

Usage

1
  average_tr_tips(tr, fossils_older_than = 0.6)

Arguments

tr

An ape phylo object

fossils_older_than

Tips that are older than fossils_older_than will be excluded from the tips that are going to be averaged. This is not currently set to 0, because Newick files can have slight precision issues etc. that mean not all tips quite come to zero (which is why you need average_tr_tips in the first place!). Obviously you should be cautious about the value of , depending on the absolute timescale of your tree. Make sure you do not inappropriately average in fossils!!

Details

If the user includes fossils accidentally, this function can easily lead to pathological results (negative branch lengths etc.), so use with care!!

Value

edge_times_bp A 2-column matrix with the age (from the present) of the top and bottom of each edge.

Note

Go BEARS!

Author(s)

Nicholas J. Matzke matzke@berkeley.edu

References

http://phylo.wikidot.com/matzke-2013-international-biogeography-society-poster

Matzke_2012_IBS

See Also

prt, chainsaw2, extend_tips_to_ultrametricize

Examples

1
test=1

Example output

Loading required package: rexpokit
Loading required package: SparseM

Attaching package: 'SparseM'

The following object is masked from 'package:base':

    backsolve

Loading required package: Rcpp
Loading required package: cladoRcpp
Loading required package: ape
Loading required package: phylobase

Attaching package: 'phylobase'

The following object is masked from 'package:ape':

    edges

BioGeoBEARS documentation built on May 29, 2017, 8:36 p.m.