How to combine neighbor cells in Grasshopper?

Hi, I would like to merge two cells together (just for the dark red part), when they are neighbors in z-direction. So each column should be clustered separately.


Can anyone help me?comm1.gh (474.5 KB)

hi,
here’s a way:
comm1.gh (471.7 KB)

Hi, unfortunatly this is not what I was asking for. Please look at my picture. I need to merge two neighbor cells in z direction. Always two single cells together. Thank you for your time!

You mean this?

Just edit _corellaman’s definition a bit and that is it.

Do you know how to filter a list with 2 items per branch and 1 item per branch into individual lists? I need two lists of sperated branch lengths

Here it is…

comm1 LeftOvers.gh (477.4 KB)

sorry I missed that - 'should have partitioned afterwards! :sweat_smile:

Thanks a lot