View source: R/03_tree_distance.R
| tree_distance | R Documentation |
Compute distances between all terminal nodes for a given tree
tree_distance(ranger_tree)
ranger_tree |
[ |
[matrix] A matrix of dissimilarities
Cesaire J. K. Fouodo
child_nodes <- list(
c(1, 0, 3, 5, 0, 0, 7, 0, 0),
c(2, 0, 4, 6, 0, 0, 8, 0, 0)
)
parent_nodes <- search_parents(ranger_tree = child_nodes)
nd <- nodes_distance(
parent_nodes = parent_nodes,
node1 = 5, node2 = 1)
tree_distance(
ranger_tree = child_nodes
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.