Group by another list of id numbers


#1

 

 

 

 

 

 

How can I regroup a list of model elements in line with another grouped list?

A python script produces a list of ID numbers… but I need to display the same list with Elements?

I tried to use the group by key?

Lists


#2

Cesar, in cases like these when I need to use custom nodes that cannot process nested lists, I first record the list structure, then flatten and process it and later reconstruct the list structure again:

SublistDeconstructReconstruct


#3

I cant read the node structure :frowning:


#4

I think the key node is List.SubListLengths, then a list chop lengths :slight_smile:

Hope that helps,

Mark


#5

Thanks Mark, I found the List.SubListLengths in clockwork 0.7. Couldn’t read the one that the flatten goes too. Just trying your comment from the other post at the moment but its erroring my dynamo


#6

Hey,

0.7?! Isn’t that pretty old? I thought they followed Dynamo numbers… could that be part of your problem?

Edit: It was deprecated… * List.SublistLengths : Use built-in node List.Count with input set to @L2 .

Hope that helps,

Mark


#7

In this instance I believe that node past the flatten is just the custom one which will then have the list structure reconstructed…