Filter out areas from lists

I’ve made a test project with masses. The masses represents houses and in those houses there is apartments and stairs and so on. What I’m trying to do is to filter out the gross floor areas for the apparments and divide them by the gross floor area of the building, which is the outer shell surrounding the apartments inside. By doing this I like to find a number that represent how effective in terms of area the building is and place this number at a parameter. But my first problem is to filter out the gross floor area of the apartments called 2-Roms, 3-Roms and 4-Roms?

I’ve tried som differrent solutions but I can’t really tell if I’m on the right track?BNFaktorTEST.dyn (14.5 KB)

Thx Rickard

To group rooms by house, you already have the house parameter (I am assuming that is what “Hus” is), so you can use getparametervaluebyname using Hus and then groupbykey node to group the original elements by house.

After that, find their parameter for area and sum them.

Let us know how far you get and we can help you.

Hello Kennyb6 and thank you!
This is where I’m at right now, as you can see I didn’t really understand the groupbykey node. But i did find another way which almost worked, now I need to filter out 2-Roms, 3-Roms and 4- roms. I’m guessing there’s an easier way to do this?

I’ll be very happy if you could explain the group by key a little further?

Many Thanks, Rickard

BNFaktorTEST02.dyn (10.7 KB)

BNFaktorTEST02.dyn (21.3 KB)
So, I found a solution but I’m sure there’s have to be a quicker way :slight_smile: Suggestions appreciated!