powered by
converts dataframe to json to send to javascript
df2tree(struct, rootname = "root", tool_tip = NULL)
data.frame containing the structure the tree will represent
character name of the root node
charater vector of the label to give to the nodes in each hierarchy
titanic_df <- as.data.frame(Titanic) df2tree(struct = titanic_df,rootname = 'Titanic') df2tree( struct = titanic_df, rootname = 'Titanic', tool_tip = letters[1:5] )
Run the code above in your browser using DataLab