AdeelK93 / collapsibleTree

Create Interactive Collapsible Tree Diagrams in R using D3.js
https://adeelk93.github.io/collapsibleTree/
158 stars 41 forks source link

Add node values from dataframe #66

Open abogadoRobot opened 2 years ago

abogadoRobot commented 2 years ago

Firstly, thank you for this amazing package!

I am struggling to add a similar values as "SizeOfNode" on every parent node, but with strings. I am able to add attributes in every children modifiying your collapsibleTree function, nonetheless without any luck with nodes.

Example of generated json with SizeofNode value: { "name" : "Test Name", "SizeofNode": 24.11, # below every parent I need to add a string "children":[{ ... }]

} Thanks again for your time and amazing work.