I am trying to re-arrange branches from a tree based on the structure from another separate tree.
As you can see below I have tree A and tree B. I would like to input the values of branches in tree A into tree B as if each value of tree B was a path of tree A.
I feel like I am missing something fundamental here as my understanding of trees tells me that the simple option 3 below should work but it is just giving me back the structure from tree A.
Option 1 does not work if tree A and B have unequal paths.
Since Tree B appears to be a direct reference to the branches in Tree A, I see no reason to believe that a mismatch between the two should yield sensible results?
Here it is again using your “Actual Trees”. I have no idea if the results make any sense. 3296 in Tree A and 3019 in Tree B results in 163735 numbers??? The basic premise seems flawed since there are only 60 branches in Tree A?
Setting List Item ‘W’ (Wrap) to False ignores references from Tree B that exceed the number of paths in Tree A, so the results are reduced to 127453 instead of 163735.
@Joseph_Oster Thanks! Your solution appears to work perfectly for my purpose. The use of the group component to input branches into a list item component in order to extract the branches is interesting and something I will try to use more.
Right now I cannot see a difference when setting the Wrap option of the list item component to True or False but I will keep that in mind if something does not seem to align down the line.
If there were no difference I wouldn’t have mentioned it. I don’t understand the full context of what you are doing but can see some consequences of this approach. With ‘Wrap = True’ (the default), index references in ‘Tree B’ that are greater than the number of branches in ‘Tree A’ create duplicates. A total of 163735 results instead of 127453 when ‘Wrap = False’. Using Cull Duplicates(CullPt) reveals that in fact, there are only 107500 unique results.