View source: R/data.tree-conversion.R
nodesToDf | R Documentation |
Convert the nodes of a tree into a data.frame
nodesToDf(tree, hierarchy)
tree |
named nested list |
hierarchy |
sorted character vector with name for each level of the list |
**Disclaimer**
These are helper functions from the github version of the shinyTree package which are very helpful to transform dataframes to nested lists and back again. These functions are not yet available (still listed as an enhancement Add data.frame -> shinyTree helper function #8 ) in the lastest version on CRAN v0.2.7 and the github version builds are currently failing. Rather than pulling the dev version of the pacakge to include these functions, adding them here until a stable version is available on CRAN. I claim no credit or ownership of any of this code. All credit should be attributed to the original authors listed on the github repo.
nested list with one level less that is stacked to a data.frame
Jasper Schelfhout jasper.schelfhout@openanalytics.eu
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.