Understanding Note Attributes in SAMSON’s Node Specification Language

If you’re a molecular modeler working with SAMSON, managing and organizing your molecular data efficiently is crucial. The note attribute space in SAMSON’s Node Specification Language (NSL) offers a way to specify and filter note-related properties of nodes in a molecular model. This blog post explores these attributes to help you streamline your workflows.

What Are Note Attributes?

The note attribute space (short name: nt) is designed to match note nodes specifically. These attributes allow you to control and query properties such as visibility, selection status, naming conventions, and more. By mastering these attributes, you can focus on the specific parts of your molecular models you’re most interested in.

Key Note Attributes

Here’s a summary of the most important attributes in the note space:

  • Visibility:
    • Use nt.hidden (h) to check if a note is hidden (true) or visible (false).
    • Use nt.visible (v) to directly query visibility status.
  • Selection:
    • nt.selected: Find out whether a note node is currently selected.
    • nt.selectionFlag (sf): Toggle selection flags to mark specific nodes for later use.
  • Naming:
    • nt.name (n): Filter note nodes by their name using quotes (e.g., nt.n "A").

Practical Use Cases

These attributes come in handy when building or analyzing molecular models. For instance:

  • You might want to quickly hide notes that aren’t relevant using nt.h true.
  • Search for note nodes with specific names, such as nt.n "L*", which matches all notes whose names start with “L”.
  • Mark important notes with nt.selectionFlag true to easily isolate them later.

An Example Table

Here’s a quick summary table of note-specific attributes for easy reference:

Attribute Name Short Name Possible Values Example
hidden h true, false nt.h, not nt.h
name n Strings in quotes nt.n "L*"
selected true, false nt.selected, not nt.selected
selectionFlag sf true, false nt.sf, not nt.sf
visible v true, false nt.v, not nt.v

Learn More

The note attribute space empowers you to organize, filter, and manipulate note nodes with precision – a valuable asset for building complex molecular models. To dive deeper into the technical details and examples, check out the full documentation here: https://documentation.samson-connect.net/users/latest/nsl/note/.

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

Comments are closed.