I have two Collapsible Force Trees for same nodes.
I haven't seen an example that we can transit from one tree to another with nodes transition and edges reconstruction in d3js.
Is there any way to do that?
Another relevant question, could we initialize the position of each node for forced-directed graph?
EDIT: Here is an example. I have two trees, the link is one, and I have another tree with same molecules but different tree structure. I am thinking it will be nice if I can animate between different trees for same molecules or entities.
linkDistance
or are you referring to some calculation you're performing in thetick
function?x
andy
properties on the nodes to initialize their position prior to handing the nodes array to the force layout, but I've had problems when setting multiple nodes to the same position - it makes the graph go crazy.