For molecular modelers working with SAMSON, the integrative molecular design platform, understanding node group attributes in the Node Specification Language (NSL) can greatly enhance your efficiency when filtering and manipulating molecular data. In this blog post, we’ll explore the essentials of node group attributes—what they are, their applications, and specific examples to streamline your modeling tasks.
What Are Node Group Attributes?
In SAMSON’s NSL, nodeGroup is an attribute space dedicated to node group nodes. These nodes allow you to group multiple items (or nodes) within a molecular system, enabling batch processing and hierarchical organization. The short name for this attribute space is ng, making it convenient to use expressions related to node groups in your work.
Key Attributes and Examples
The nodeGroup attribute space comes with three key attributes, inherited from the node attribute space:
1. name
Understanding the name attribute is crucial when working with specific node groups in your molecular models. This attribute matches string-based names enclosed in quotes. For example:
ng.n "A": Selects the node group named “A”.ng.n "L*": Selects all node groups with names starting with “L”.
This inherited attribute simplifies model organization and makes identifying groups much easier.
2. selected
The selected attribute allows you to filter node groups based on whether they are selected or not. Its possible values are true and false. While it lacks a short name, you can easily use expressions like:
ng.selected: Selects all currently selected node groups.not ng.selected: Selects all node groups that are not selected.
Efficient use of the selected attribute helps save time during large-scale modeling or result analysis.
3. selectionFlag
Similar to selected, the selectionFlag attribute evaluates whether a node group has a specific selection flag set. This attribute is also boolean, with true or false values, and has a short name, sf. You can use expressions such as:
ng.sf false: Selects node groups that do not have the selection flag set.ng.sf: Matches node groups with the selection flag set.
The selectionFlag attribute proves invaluable when handling groups conditionally based on actions or states.
Why Node Group Attributes Matter
For complex molecular models, efficiently referencing and manipulating groups of nodes is often necessary to analyze structures, simulate interactions, or prepare data for visualizations. Leveraging these attributes prevents manual grouping errors and improves the reproducibility of workflows within SAMSON. With concise yet powerful expressions available through the NSL, you’ll find managing intricate models far more straightforward.
Learn More
To explore the full details of node group attributes in NSL, including advanced use cases and additional examples, visit the official documentation page.
SAMSON and all SAMSON Extensions are free for non-commercial use. You can download SAMSON here.
