Last data update: 2014.03.03
|
R: Identification of Sister Nodes and Clades
Identification of Sister Nodes and Clades
Description
For any given internal node in a phylogeny, this function returns the sister clade
Usage
sister(phy, node, type = "terminal")
Arguments
phy |
an object of class phylo .
|
node |
an integer giving the number of the node.
|
type |
a character string, may be "terminal" , "internal" , "both" , or any unambiguous abbreviation of these.
|
Value
A vector containing node numbers.
Author(s)
Christoph Heibl
See Also
descendants , noi
Examples
# data
# ----
#data(vipera)
#node <- noi(vipera.ml, c("Vipera_latastei", "Vipera_aspis"))
# get the sister node of 'node'
# -----------------------------
#(sn <- sister(vipera.ml, node, type = "internal"))
# ... and the sister nodes's tips (i.e. the sister clade)
# -------------------------------------------------------
#(sc <- sister(vipera.ml, node, type = "terminal"))
# results graphically:
# --------------------
#plot(vipera.ml)
#nodelabels(text = "15", node = 15, frame = NULL, col = "white", bg = "black")
#nodelabels(text = sn, node = sn, col = "black", bg = "red")
#append2tiplabel(tree, tips = sc, pch = 21, offset = strwidth("."))
Results
|