coaltime {phybase}R Documentation

Coalescence time of two nodes

Description

The function computes the coalescence time of two nodes.

Usage

coaltime(inode, jnode, nodematrix, nspecies)

Arguments

inode the first node, it could be an internode.
jnode the second node, it could be an internode.
nodematrix the tree node matrix
nspecies the number of species

Value

the function returns the coalescence time of inode and jnode.

Author(s)

Liang Liu

See Also

popsize

Examples

treestr<-"((((H:0.00402,C:0.00402):0.00304,G:0.00706):0.00929,O:0.01635):0.1,W:0.11635);"
taxaname<-species.name(treestr)
nodematrix<-read.tree.nodes(treestr,name=taxaname)$nodes 
coaltime(1,2,nodematrix,5) #the coalescence time of taxa H (1) and C (2).

[Package phybase version 1.1 Index]