List from other sublist


I have certain elements in some rooms, to which I want to add parameters related to that room. Everything else is solved except the issue of creating a list of rooms which contain element with same index as those elements.

Looking at the following image, I would like to get Room list with only those rooms which have that element. So if I have 2 or more elements in same room (this creates sublist of elements) that I have that room same number of times in the list on same index as element.

I hope you understand my point.

After Elements in Room try a IsNull node to see which sublists have elements in them. Then use FilterByBoolMask to filter your list of rooms for those with elements.

1 Like

I’m facing exactly the same Problem at the moment. I’m using Room.IsInsideRoom to check (set to cross product). This function is also used by your node from archilab. I Need to check against Points of the Family Location because my rooms come from an linked file (imported at the wrong Location so I Need to move the Points of the Family - other story :D).

That gives me an list with all rooms at first Level and second level a boolean for each element in my list. I then check the index of each “true” element and retrieve the element.

At some point I have a list with 4 rooms (as example) which have 0-3 elements inside.

To export a list to Excel I need two lists with same length. This is my solution and I think it’s also what you’re looking for:

1 Like

Rhythm also has a node Element.Room which returns the room an element is in. You’d be able to use this along with GroupByKey to get your elements by room.