A large molecular structure can be hard to inspect one residue at a time. Maybe you need to find every alpha-helical residue, isolate charged side chains, or check whether a structure contains unusual residue names. The challenge is not just locating a residue—it is expressing the question precisely enough to repeat it and adapt it.
SAMSON’s Node Specification Language (NSL) lets you search residues by properties such as type, secondary structure, charge, sequence number, and atom counts. Residue queries use the residue attribute space, abbreviated r. That means a query such as r.t ALA matches alanine residues, while r.ss h matches residues in alpha helices.
Start with the biological question
It helps to translate an inspection task into a property before writing a query. For example:
- “Show me the helix residues.” Use
r.ss h. The aliasesalpha,a, andhelixare also accepted. For beta strands, user.ss b; for loops or unstructured regions, user.ss u. - “Find a particular residue type.” Use
r.t HISfor histidines orr.t LYS, PROfor lysines and prolines. The documented type values include standard amino acids as well as several nucleic-acid residue codes. - “Inspect residues by side-chain charge or polarity.” Use
r.c negfor negatively charged side chains, orr.p polarfor polar side chains. You can provide multiple values, as inr.c neu, pos. - “Check the ends of a chain.” Use
r.terto match terminal residues.
These queries make a useful first-pass checklist: identify a structural region, inspect particular residue types, then investigate charge or polarity where it matters. You can run the questions separately and compare the resulting matches rather than trying to reason about a whole structure visually.
Use ranges to narrow the search
Residue sequence numbers and numerical properties can be queried with comparisons or ranges. For example, r.id 1:10, 20:30 matches residues whose sequence numbers fall in either interval. To focus on residues with a small atom count, try r.nat < 100; to examine formal charge, use a query such as r.fc 6:8. Partial charge is available through r.pc, and atom-count attributes include carbon, hydrogen, nitrogen, oxygen, and sulfur counts.
Ranges are particularly handy when you already know the region or threshold you care about. They can turn “look around the middle of the sequence” or “find unusually large residues” into a repeatable filter. Keep in mind that a residue’s sequence number is a structure ID; it is not the same as its residue type.
Know whether you want residues or atoms
A small but important distinction: residue attributes match residues, while some expressions can use a residue query to find atoms within those residues. For instance, n.t a in r.aa matches atoms in amino-acid residues. Likewise, "CA" in r.t VAL matches alpha-carbon atoms in valine residues. This is useful when the biological question concerns a particular atom, but the context that identifies it is the residue it belongs to.
Some attributes describe the residue as it appears in the structure, while others depend on residue type. Secondary structure and sequence number can vary with the structure or system; properties such as amino-acid classification, charge, and polarity are associated with residue type. That distinction helps when interpreting a match: a result about polarity is a type-based classification, not a measurement of the local environment.
For a practical inspection, begin with a broad query, then refine it using the feature that answers your question—type, sequence range, secondary structure, or chemistry. The full list of residue attributes and examples is in the SAMSON residue attributes reference.
Note: SAMSON and all SAMSON Extensions are free for non-commercial use. Get SAMSON.
