create_tree: create tree appended with each element of input list as a...

View source: R/node.R

create_treeR Documentation

create tree appended with each element of input list as a child

Description

create tree appended with each element of input list as a child

Usage

create_tree(input_list, node_name)

Arguments

input_list

input list to be made for a tree

node_name

name of the tree

Value

a tree with each item of the list as each child

Examples

data("test_df")
test_node <- data.tree::as.Node(test_df)
new_shape <- create_tree(test_node$children,"new_tree")
print(new_shape, "hc")


forestry documentation built on Nov. 21, 2023, 1:07 a.m.