View source: R/tree_descendants.R
| NDescendants | R Documentation |
NDescendants() counts the number of nodes (including leaves) directly
descended from each node in a tree.
NDescendants(tree)
tree |
A tree of class |
NDescendants() returns an integer listing the number of direct
descendants (leaves or internal nodes) for each node in a tree.
Martin R. Smith (martin.smith@durham.ac.uk)
Other tree navigation:
AncestorEdge(),
CladeSizes(),
DescendantEdges(),
EdgeAncestry(),
EdgeDistances(),
ListAncestors(),
MRCA(),
MatchEdges(),
NodeDepth(),
NodeNumbers(),
NodeOrder(),
RootNode()
tree <- CollapseNode(BalancedTree(8), 12:15)
NDescendants(tree)
plot(tree)
nodelabels(NDescendants(tree))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.