Model.maskentitiesincollector#

Model.maskentitiesincollector(collection, flag_1, flag_2, flag_3, flag_4, flag_5, flag_6)#

Masks the entities in the collection. Only entities in displayed collectors may be masked.

The six flag arguments indicate the type of entities to mask within the specified collectors. If the flag is set to 1, that entity is masked. If the flag is set to 0, that entity is not modified. See the list below for the currently supported entity_types and flags.

Parameters:
  • collection (Collection) – The collection containing the entities to be masked.

  • flag_1 (int) –

    • For components: Elements

    • For groups: Main elements

    • For load collectors: Loads

  • flag_2 (int) –

    • For components: Points

    • For groups: Secondary elements

    • For load collectors: Equations

  • flag_3 (int) –

    • For components: Lines

    • For groups: -

    • For load -

  • flag_4 (int) –

    • For components: Surfaces

    • For groups: -

    • For load -

  • flag_5 (int) –

    • For components: Solids

    • For groups: -

    • For load -

  • flag_6 (int) –

    • For components: Connectors

    • For groups: -

    • For load -

Example#

Mask all of the points and surfaces in the displayed components#
import hm
import hm.entities as ent

model = hm.Model()

comps = hm.Collection(model, ent.component)
model.maskentitiesincollector(
    collection=comps, flag_1=0, flag_2=1, flag_3=0, flag_4=1, flag_5=0, flag_6=0
)