A molecular model can contain many segments, and the one that needs attention is not always obvious from a visual inspection. A segment may contain more residues or atoms than expected, or its composition and charge may be worth checking before you move on. In SAMSON, the Node Specification Language (NSL) lets you describe these properties as expressions and find matching segment nodes.
The useful starting point is scope: the segment attribute space, abbreviated s, matches only segment nodes. That makes segment-level searches distinct from searches for individual residues or atoms. For example, s.nr > 100 looks for segments with more than 100 residues; it is not a query for individual residues.
Start with size, then narrow the question
If you are looking for segments with many residues, use s.nr, the short name for numberOfResidues. The expression s.nr > 100 matches segments above that threshold. If you already have a useful interval in mind, write s.nr 100:120 to match segments with a residue count between 100 and 120.
Residue count is only one way to assess size. A segment can also be checked by its number of atoms using s.nat, or by its number of structural groups using s.nsg. For example, s.nat < 1000 looks for segments with fewer than 1,000 atoms, while s.nsg > 10 finds segments with more than 10 structural groups.
These measures answer different questions. Residue count is useful when you are thinking in terms of sequence or polymer length. Atom count gives a direct count of atoms in the segment. Structural-group count offers another structural measure. If something seems unexpectedly large, checking more than one count can help you describe the issue precisely rather than relying on a single number.
Use composition and charge as follow-up checks
Segment attributes also include inherited counts for specific elements. For example, s.nC < 10 searches for segments with fewer than 10 carbons, and s.nO 10:20 searches for a segment with between 10 and 20 oxygens. The available element-count abbreviations include nC, nH, nN, nO, and nS.
Charge can be another useful check when investigating a segment. s.fc refers to formal charge, which takes integer values; for instance, s.fc > 1 matches segments with formal charge greater than 1. s.pc refers to partial charge, which takes floating-point values, so an expression such as s.pc 1.5:2.0 checks for values in that range.
Make the thresholds work for your model
Example numbers are starting points, not universal definitions of an unusually large or unusual segment. A threshold that is useful for one model may be irrelevant for another. Begin with a broad comparison—such as s.nr > 100—then adjust the value to reflect the scale and organization of the structure you are examining. An interval such as s.nat 100:200 can be useful when you want to inspect a particular range instead of everything above a cutoff.
NSL also exposes inherited node attributes such as name, visible, and selected. The segment name can be queried with expressions such as s.n "A". One detail to note: the documentation lists selected without a short name in this attribute space, so use s.selected rather than assuming it has a compact abbreviation.
A practical habit is to turn a vague concern—“this part seems large”—into a measurable question: how many residues, atoms, or structural groups does the segment contain? Then use the corresponding attribute to find segments matching a chosen threshold. This keeps the search focused on segment nodes and makes the criteria explicit and repeatable.
For the complete attribute reference and additional examples, see the SAMSON segment attributes documentation.
Note: SAMSON and all SAMSON Extensions are free for non-commercial use. Get SAMSON.
