Count air devices in space

Hi
I need help, I’m a bit stuck.
I’m trying to count all the different airdevices in a space, rename them, like TD1, TD2… Then i want to count how many I’v got of each in any given space.

my end gol is to writer to a parameters. But that is a later problem.
6xTD1
1xFD2

Thanks in advance!

Did you check, there are similar posts in this forum…

https://forum.dynamobim.com/search?q=elements%20in%20room

1 Like

Hi
Thanks for the reply, yes I’ve searched. If I’m a terrible searcher, the help to find the right thread where i can find my answere would be much appreciated!
Thats how I’ve got to the point to get a list of all air-devices in a list. within a list of all spaces. But its the summary that is the problem now. I need to get from the poit:

[0]MTN-400 + HMK-250/400
[1]MTN-400 + HMK-250/400
[2]MTN-400 + HMK-250/400
[3]MTN-400 + HMK-250/400
[4]MTN-400 + HMK-250/400
[5]MTN-400 + HMK-250/400
[6]RASTER GRL 595x595

to

[0]6xTD2
[1]1xFD1

The translation part I’ve managed, so now i have a list with

[0]TD2
[1]TD2
[2]TD2
[3]TD2
[4]TD2
[5]TD2

  1. List.GroupByKey with both inputs as your translated list.

  2. Count the groups.

  3. Join the count to the separator text and the Key from the group by key node.