A crowded molecular scene can be difficult to troubleshoot. You may be trying to find a presentation node by name, check which ones are selected, or narrow down what is visible—but a query that targets the wrong kind of node can send you in circles.
The presentation attribute space in SAMSON’s Node Specification Language (NSL) offers a focused starting point. Its short name is pr, and it matches presentation nodes only. That scope is useful when your question concerns presentation attributes rather than the properties of other nodes in the document.
Start by making the target explicit
Use the pr prefix to make it clear that the attribute you are querying belongs to the presentation attribute space. For example, pr.n "A" queries the name attribute, while pr.h queries the hidden attribute. The full name presentation is the attribute-space name; pr is its short form.
This small habit makes filters easier to read later. When you revisit a query, the prefix reminds you that it is intended to match presentation nodes—not every node that might have a similarly named property.
Keep visibility terms distinct
The reference lists three visibility-related attributes: hidden (h), visible (v), and visibilityFlag (vf). Each accepts true or false. Examples include:
pr.hto query the hidden attribute, ornot pr.hfor its negated form.pr.vto query the visible attribute, ornot pr.vfor its negated form.pr.vf falseto query a specific visibility-flag value.
Although these names all relate to visibility, the reference lists them as separate attributes. Avoid silently substituting one for another in a query. If you are investigating a display issue, try the attribute that matches the question you are asking, and keep the expression explicit.
Selection has the same naming trap
Selection-related queries include selected and selectionFlag. The selected attribute has no short name in the presentation space; the selection flag uses sf. Examples are pr.selected, not pr.selected, pr.sf, and pr.sf false.
That distinction can help when a presentation node is not appearing in the results you expected. Check which attribute your expression actually uses: pr.selected and pr.sf are different expressions, and the documentation presents them as separate attributes. Do not assume that one is an alternate spelling of the other.
Use names to narrow the search
The name attribute accepts strings in quotes. The reference gives pr.n "A" and pr.n "L*" as examples. Quoting the name keeps the string clearly separated from the attribute expression. If you are testing a name-based query, begin with a simple example and then adjust the quoted string to the name you need.
A quick troubleshooting routine
- Confirm that you want to query presentation nodes; use the
prattribute-space prefix. - Identify the exact property you mean:
hidden,visible,visibilityFlag,selected, orselectionFlag. - Use the documented short name where available:
h,v,vf, orsf. Forselected, use the full name. - Check the expression’s value or negation carefully. For example,
not pr.vis not the same written query aspr.h. - If searching by name, put the string in quotes, as in
pr.n "A".
The main benefit is precision: choose the attribute that describes the state you want to inspect, and make the presentation-node scope visible in the expression. For the complete attribute list and examples, see the SAMSON presentation attributes reference.
Note: SAMSON and all SAMSON Extensions are free for non-commercial use. Get SAMSON.
