A crowded molecular scene can make it difficult to focus on the representation you actually need. Before changing anything, it helps to be able to ask a precise question: Which presentation nodes are visible? Which are hidden? Which are selected? In SAMSON, the presentation attribute space in Node Specification Language (NSL) provides a compact way to describe those matches.
This is useful when you are inspecting a complex model and want to narrow your attention to a particular state of the scene. Rather than relying on a visual search alone, you can form a readable expression around a presentation attribute and use it to identify matching presentation nodes. The key detail is the attribute space: presentation, abbreviated pr, matches only presentation nodes.
Start with visible and hidden
For a quick check of presentation visibility, use pr.v to express the visible attribute, or not pr.v to express its opposite. The full attribute name is visible; its short name is v. These two forms give you a concise way to describe visible and non-visible presentations when building a specification.
The inherited hidden attribute offers another useful filter. Its short name is h, so the documented forms include pr.h and not pr.h. Because hidden and visible are separate attributes in the reference, keep the distinction clear when writing a query: use the attribute that describes the condition you want to match, rather than assuming one name is simply a shortcut for the other.
Keep selection checks distinct
Presentation nodes also inherit selected and selectionFlag. You can write pr.selected or not pr.selected to express the selected state. Unlike the node attribute space, the presentation version of selected does not have the short name s. The separate selectionFlag attribute does have a short name: sf. The reference gives pr.sf and pr.sf false as examples.
That distinction matters when you are trying to make an expression easy to understand later. If your question is about whether a presentation is selected, spell out pr.selected. If you specifically need the selection flag attribute, use pr.sf. Keeping these terms separate makes it easier for a collaborator—or your future self—to see what a specification is intended to check.
Use names to narrow the search
The inherited name attribute can help focus a specification on named presentations. Use pr.n as its short form, followed by a name in quotes. The documentation examples include pr.n "A" and pr.n "L*". This gives you a practical starting point when a scene contains multiple presentations and you already know the name you want to investigate.
A simple way to build a specification
-
Decide what you are trying to find: a visible presentation, a hidden one, a selected one, or one with a particular name.
-
Choose the corresponding attribute: for example,
visible,hidden,selected, orname. -
Add the
prprefix to make the presentation attribute space explicit, then use the short name where one is available. -
Use
notwhen you need the opposite boolean condition, as innot pr.v.
These expressions are small, but the habit of making the target and condition explicit can reduce confusion when a molecular scene contains many presentation nodes. The presentation reference lists the available inherited attributes, their short names, possible values, and examples. For the full details, see the SAMSON presentation attributes documentation.
Note: SAMSON and all SAMSON Extensions are free for non-commercial use. Get SAMSON.
