One of the key tools for molecular modelers is the ability to organize, filter, and manage nodes efficiently. If you’ve ever been frustrated by a cluttered molecular model or found it difficult to isolate specific details, this overview of label attributes in SAMSON’s Node Specification Language (NSL) may transform your workflow.
What are Label Attributes?
The label attribute space, identified by the short name la in the Node Specification Language, is a way to define and work specifically with label nodes in SAMSON. It allows modelers to manage the visibility, selection, and naming attributes of these nodes, ensuring that their molecular models remain organized and adaptable.
Key Attributes and How They Help
The table below breaks down some of the most frequently used label attributes within this space:
| Attribute name | Short name | Possible values | Examples |
|---|---|---|---|
| hidden | h |
true, false |
la.h, not la.h |
| name | n |
strings in quotes | la.n "A", la.n "L*" |
| selected | None | true, false |
la.selected, not la.selected |
| selectionFlag | sf |
true, false |
la.sf false, la.sf |
| visibilityFlag | vf |
true, false |
la.vf false, la.vf |
| visible | v |
true, false |
la.v, not la.v |
How These Attributes Support Your Work
- hidden: Allows users to toggle whether a label is hidden, which is essential when decluttering a complex molecular model.
- name: Useful for searching or organizing labels by custom names or patterns. Wildcards like
"L*"simplify pattern searches. - visible: Acts as the counterpart to
hidden, helping users identify shown nodes specifically. - selected and selectionFlag: Enable modelers to isolate and focus on specific nodes or labels in their model.
- visibilityFlag: Useful for tracking temporary states where visibility is modified programmatically or interactively.
Practical Example
Imagine you have a complex protein structure with numerous labels for specific residues and functional groups. Here’s how these attributes can simplify your workflow:
Let’s say labels for residues starting with ‘A’ are cluttering your viewport. By setting la.n "A*" and not la.h, you can target and hide these labels, transforming your screen into a cleaner, more manageable workspace. If you want to quickly review only the visible labels, query la.v to isolate them. This level of control allows you to focus exactly where you need to without distractions.
Explore More!
Label attributes form just a part of SAMSON’s powerful Node Specification Language. For a more detailed breakdown of label-specific tools, visit the original documentation page.
SAMSON and all SAMSON Extensions are free for non-commercial use. Start leveraging these features today by downloading it at SAMSON Connect.
