Find tree branch and index

Hello guys,

I have a list of numbers that I have obtained after performing certain Boolean functions. I know for a fact that these numbers occur in a data tree that I already have. I would like to know the branch path of the tree and at what index that item is. Is this possible?

I’ve tried using member index and playing around with it, but somehow it is giving me extra branch paths.

Thanks in advance

find tree branch and (11.1 KB)

This could be one way, BTW there might be more simpler ways…

find tree branch and (14.0 KB)

Same result…

find tree branch and (16.9 KB)

hello, thanks for the reply,

I tried modifying it a bit because that wasn’t exactly what I was looking for. I want the output to be such that I can directly plug it into the tree branch/tree item component to get a specific value. Almost like a list item component but for items in trees.

I still couldnt get it quite right, I dont know exactly how the replace path works. I couldnt get the list to come out in the original order, it seems to be coming out in an ascending order.


find tree branch and (13.7 KB)

You can use sort to modify the order, but …
I really don’t know why you want to get back to the same list that you have already found using list item through a difficult process. I don’t understand…

find tree branch and (16.8 KB)

Thank you so much!

Sorry for not telling you the whole picture, it does seem silly to get the original data after performing various tedious operations, making it seem pointless.
But it’s actually not the same list that I want to match. Instead, it is a list that has the exact data structure as the originally supplied list.

So, I used your method and ran that new list through to get the desired outcome.

I thank you again for your time and patience, it is much appreciated! :smile:

find tree branch and (19.8 KB)