Generate Groups by Property

Jiri Hietanen
Jiri Hietanen
  • Updated

The Generate Groups by Property tool divides objects into groups based on the values of a text property. The tool creates one group for each unique value and adds the objects that have the value to that group. You don't need to know the values or the names of the groups in advance.

For example, you can group the walls by their fire rating to get one group for the EI30 walls, one for the EI60 walls and so on. You can then use these groups like any other groups, for example, as the target of another tool.

The generated groups are manual groups. They don't follow later changes in the property values, so you need to run the tool again when the values have changed. Objects can be added to and removed from the groups in the user interface via drag&drop.

There are also other ways to create groups:

  • To divide the objects of one existing group into child groups, use the Generate Child Groups by Property tool. It can also create rule based child groups.
  • To create a single group, or a group defined by a rule, use the Add or Modify Group tool.
  • The Generate Groups by Text Property dataflow does a similar grouping under a parent group, and creates the parent group if it is missing.

How the objects are divided

  • Upper and lower case letters are treated as the same value. For example, EI60 and ei60 end up in the same group. The spelling that the tool finds first becomes the name of the group.
  • Objects that have the property but no value for it go to a group called <no value>. A value that contains only spaces counts as no value.
  • Objects whose object class does not have the property go to a group called <not applicable>.

You can turn off the last two groups in the settings. They are created only when there are objects for them. If you use Simplebim in another language, the names of these two groups are in that language.

After the run, the tool reports how many groups it generated from how many objects, how many existing groups it deleted first and how many objects it did not group.

Several levels of groups

If you list several properties in the Grouping Property setting, the tool builds a hierarchy of groups. The first property divides the objects into groups, and each further property divides every group of the previous level into child groups. All the levels use the same settings and the same group category.

For example, with the properties Fire rating and Material the result can look like this:

  • EI30
    • Concrete
  • EI60
    • Concrete
    • Steel
  • <no value>
    • Concrete

Settings

Objects to Group

Defines the objects that are divided into groups. You can select, for example, the objects of an object class or a group. 

If the selection does not find any objects, the tool reports a warning and does not change the model.

Group Category

Defines the category of the generated groups. You can use the name or the key of the category. The default value is Generic Group.

Parent Group (optional)

This is an optional setting. If you leave it empty, the groups are created directly under the Group Category defined above.

Otherwise, the groups are created as child groups of the group with this name. The parent group can be a child group itself. The parent group must exist in the model and belong to the Group Category defined above, and the name must match exactly one group. Otherwise, the tool reports an error and does not change the model.

Grouping Property

Defines the name or identity key of the property whose values are used for generating the groups. This setting is mandatory.

You can list several properties to create several levels of groups. The same property can be listed only once.

Only text properties can be used. The property must be a text property with a single value in every object class that has it among the Objects to Group. If it is, for example, a number or a list of values in one of these object classes, the tool reports an error and does not change the model. To group objects by a number or another type of value, first copy the values to a text property with the Copy Property Values tool.

If an object class has several properties with the same name, for example in different property sets, the tool reports an error and does not change the model. Use the identity key of the property in this case.

Create Group for <not applicable>

If ON, objects whose object class does not have the Grouping Property are collected to a group called <not applicable>. If OFF, these objects are not grouped. The default value is ON.

Create Group for <no value>

If ON, objects that have the Grouping Property but no value for it are collected to a group called <no value>. If OFF, these objects are not grouped. The default value is ON.

Non-overlapping Child Groups

If ON, an object can belong to only one child group of a generated group. If you add an object to a child group, it is removed from the other child groups of that generated group. This restriction applies only to manual child groups. The setting applies to the generated groups on every level. The default value is OFF.

Limit Child Groups

If ON, child groups that may be added to a generated group later can only have objects that the generated group has. This restriction applies only to manual child groups. The setting applies to the generated groups on every level. The default value is OFF.

Clear Existing Groups

Defines what happens to the groups that already exist at the level where the new groups are generated. The default value is ON.

If ON, the tool first deletes the existing groups, so you get a clean result when you run the tool again:

  • Without a Parent Group, the tool deletes the top-level groups of the Group Category.
  • With a Parent Group, the tool deletes the child groups of the parent group that belong to the Group Category.

The child groups of the deleted groups are deleted with them, even if they belong to another category.

The tool deletes these groups no matter how they were created. For example, if you generate groups into the IFC Group category, the top-level IFC groups that came with the model are deleted too. If you run the tool twice with different Objects to Group into the same category and level, the second run deletes the groups of the first run. Turn this setting OFF in these cases.

If OFF, the existing groups stay in the model and the new groups are added next to them. If a group with the same name already exists in the same category and at the same level:

  • A manual group gets the new objects in place of its old objects. It keeps its child groups and its own Non-overlapping Child Groups and Limit Child Groups settings.
  • A rule based group is converted into a manual group.
  • A container group cannot be replaced. The tool reports an error and stops, and the groups it generated before that stay in the model. The same happens if several groups with that name exist.

A group for a value that no longer exists stays in the model with its old objects. You can remove such groups with the Delete Groups tool.

Release Notes

This tool was added in Simplebim 12.0 SR1

Was this article helpful?

0 out of 0 found this helpful

Have more questions? Submit a request

Comments

0 comments

Please sign in to leave a comment.