treeCompare: Visualize the difference between phylogenetic trees

treeCompareR Documentation

Visualize the difference between phylogenetic trees

Description

The function scans a pair of phylogenetic trees to find topological differences.

Usage

treeCompare(tree,tree1,focal=NULL,plot=TRUE)

Arguments

tree, tree1

a phylogenetic tree. The tree needs not to be ultrametric and fully dichotomous. Generic name and specific epithet must be separated by '_'.

focal

a vector of focal species to search on both tree and tree1.

plot

if TRUE, the function produces an interactive plotting device to check differences in species placement at the genus level.

Value

The function returns a data-frame indicating for each un-matching/focal species its sister species/clades on both trees.

Author(s)

Giorgia Girardi, Silvia Castiglione, Carmela Serio, Antonella Esposito

Examples

## Not run: 
DataFelids$tree->treefel

set.seed(22)
drop.tip(treefel,sample(treefel$tip.label,20))->tree.red
swapONE(tree.red,si=0.5)[[1]]->tree.red

sample(tree.red$tip.label,10)->focal.species

treeCompare(treefel,tree.red)->comp
treeCompare(treefel,tree.red,focal=focal.species)->comp1


## End(Not run)

RRphylo documentation built on April 3, 2025, 9:43 p.m.