powered by
maxdist uses ancestral state reconstruction to determine the maximum distance between any ancestors of those two taxa.
maxdist(phyl, phendata, t1, t2)
The phylogeny of interest in phylo format
Phenotypic data for all tips
The first taxon of interest
The second taxon of interest
The maximum phenotypic distance between the two taxa
Returns the maximum Euclidean distance between any pair of ancestors of the two taxa, whether or not those two ancestors are contemporaries.
Paradis, E., J. Claude, and K. Strimmer (2004) APE: Analyses of phylogenetics and evolution in R langauge. Bioinformatics, 20, 289-290.
Revell, L. J. (2012) phytools: An R package for phylogenetic comparative biology (and other things). Methods Ecol. Evol. 3 217-223.
# NOT RUN { phyl<-rtree(10) phendata<-fastBM(phyl,nsim=2) answer<-maxdist(phyl,phendata,1,10) # }
Run the code above in your browser using DataLab