"Stack" branches - tree problem

Hello,

I have a problem with my definition. To illustrate it i made a simple definition - I have a tree with 3 branches. What i need to do is create a tree that “stacks” data in branches in a way that it takes all items from ALL branches that are above. As seen in the picture:

I made it using merge and entwine in given example. The thing is number of branches is dynamic in the definition (so is number of items). Is there a way to do it otherwise?

Also - what can i do to “stack” sub-branches only? - For example if the structure is {A;1}; {A;2}; {A;3}; {B;1}; {B,2}; {C;1}; {C;2}; {C;3} and i need to “stack” values to still be separated as A; B and C.

Hi,

this could be one of possible solutions

For 2nd task you can use Shift Paths or Path Mapper or Trim Tree or …

1 Like