A large molecular model can be hard to inspect one backbone at a time. You may be looking for a group with a particular atom count, checking which backbones carry a formal charge, or trying to distinguish visible from hidden nodes. Scanning the structure manually is slow—and it is easy to overlook a candidate.
SAMSON’s Node Specification Language (NSL) lets you describe the backbone nodes you want to find using attributes. The useful shift is to turn a visual search into a specific question: Which backbone nodes match this property? The examples below use the bb prefix shown on the reference page.
Start with a size or composition question
If you need to narrow a model by size, use numberOfAtoms, abbreviated nat. For example, bb.nat < 1000 matches backbones with fewer than 1,000 atoms, while bb.nat 100:200 expresses a range from 100 to 200.
Element counts can make the search more specific. The short names are nC for carbons, nH for hydrogens, nN for nitrogens, nO for oxygens, and nS for sulfurs. For instance, bb.nO < 10 filters for backbones with fewer than ten oxygens; bb.nC 10:20 specifies a carbon-count range. These attributes describe the backbone node’s counts, so they are useful when the unit you want to compare is a backbone rather than an individual atom.
There is also numberOfCoarseGrainedAtoms, abbreviated ncga. A query such as bb.ncga < 1000 can help when coarse-grained atom count is the relevant measure. Choosing the count that reflects your model representation is a simple way to avoid filtering on a quantity that does not answer your actual question.
Check charge without relying on appearance
Charge is another property that can be difficult to judge from a structural view alone. Use formalCharge (fc) for integer values: bb.fc > 1 selects values greater than one, and bb.fc 6:8 specifies a range. The reference also lists partialCharge (pc) as a floating-point attribute, with examples such as bb.pc > 1.5 and bb.pc 1.5:2.0.
These are different attributes, so choose the one that corresponds to the question you are investigating. If you are comparing results with a colleague, writing down the attribute and threshold makes the filtering criterion much clearer than describing a region by how it looks.
Separate what a node is from how it is displayed
Backbone nodes inherit several general node attributes. To check display or interaction state, the page gives examples including bb.v for visible, not bb.v for not visible, bb.h for hidden, and bb.selected for selected. The selection and visibility flags can also be queried explicitly: bb.sf false and bb.vf false.
Keeping these questions distinct can make a troubleshooting search easier. A composition or charge filter asks what properties a backbone has; a visibility or selection filter asks about its current node state. If a backbone seems to be missing from view, checking visibility-related attributes is a more direct starting point than changing your chemical criteria.
Use short names when repeated queries get bulky
NSL provides compact names for many attributes: nat, nC, fc, and pc, for example. The longer attribute names are easier to interpret while learning; the short forms are convenient once you recognize them. The backbone attribute space has short name s, but note that the documentation says selected does not use that short name. Its examples use bb.selected.
A practical habit is to begin with one clear criterion, confirm that it reflects the property you care about, and then refine your search using another relevant attribute. The reference page lists the available backbone attributes, their value types, and example expressions. Learn more in the Backbone attributes documentation.
Note: SAMSON and all SAMSON Extensions are free for non-commercial use. Get SAMSON.
