Decoding Property Model Attributes in SAMSON

If you’re a molecular modeler working with SAMSON, one challenge you may face is efficiently filtering, selecting, or analyzing specific nodes in your complex molecular designs. The property model attribute space in the Node Specification Language (NSL) offers a structured solution to this by enabling streamlined interaction with property model nodes based on various attributes.

The propertyModel attribute space, identified by the short name pm, specifies attributes unique to property model nodes. Understanding how to leverage these attributes can save you significant time and effort when organizing or manipulating molecular models. Let’s dive into some of the key attributes and how they might help simplify your workflows.

Highlights of Property Model Attributes

The propertyModel attribute space includes several attributes, each of which serves a unique purpose. Here’s a closer look:

  • hasMaterial (pm.hm): Indicates whether a property model node is linked to material. Possible values are true or false. For instance, you can use pm.hm to filter nodes with material and not pm.hm to select ones without material.
  • hidden (pm.h): Denotes whether a node is hidden. By specifying pm.h true, you can isolate hidden nodes in your design.
  • name (pm.n): Filters nodes based on their names. You can use exact matches, such as pm.n "A", or wildcards, like pm.n "L*", to list all nodes starting with the letter “L”.
  • ownsMaterial (pm.om): Specifies whether the node owns the material. For example, pm.om alone selects nodes with owned material, whereas the absence of om selects those without.
  • selected (pm.selected): Indicates whether a node is currently selected. Use pm.selected to filter selected nodes or not pm.selected for unselected ones.
  • selectionFlag (pm.sf): Similar to selected, but used to manage selection flags of nodes. For example, pm.sf or pm.sf false can be employed to refine selections further.
  • visibilityFlag (pm.vf): Specifies the visibility state of a node. Using pm.vf false can help focus on invisible nodes, whereas pm.vf works for visible ones.
  • visible (pm.v): Another attribute controlling visibility, pm.v can be used for visible nodes while not pm.v targets hidden ones.

Example Use Cases

Consider a project in which you need to verify which nodes are invisible while owning specific material. By combining the attributes pm.vf, pm.hm, and pm.om, you can write a concise query tailored to your needs.

For instance:

This will list all invisible nodes (with true visibilityFlag set to false) that also own material.

Why Focus on Attribute Spaces?

The beauty of NSL in SAMSON is evident in how it empowers users to customize their workflows. Attributes like pm.n (name) make it easy to find nodes that match specific patterns, while attributes like visible and hidden improve accessibility during complex modeling tasks.

If you’re a beginner in SAMSON, the propertyModel attribute space can significantly reduce the trial-and-error it takes to locate or refine specific molecular designs. By mastering these simple yet powerful attributes, you’ll streamline your process and build more robust molecular systems.

For a more comprehensive understanding of each of the attributes and their detailed syntax, visit the official documentation page: https://documentation.samson-connect.net/users/latest/nsl/propertyModel/.

SAMSON and all SAMSON Extensions are free for non-commercial use. You can download SAMSON at https://www.samson-connect.net.

Comments are closed.