A selection that looks right at first glance can quietly include more than you intended. In a molecular model, typing LYS into the Document view’s filter may select lysine residues, but it can also select their backbones and side chains because those nodes have names containing the same text. That matters when you are about to inspect, edit, visualize, or otherwise act on the selected nodes.
The useful distinction is this: a name filter matches text in node names, while a Node Specification Language (NSL) expression can target a specific node type and property. Here is a practical way to make a residue-level selection precise, check what was selected, and reuse the query later.
Start with the Document view
Open the Document view if it is not already visible: choose Interface > Document view. Its hierarchy lets you inspect the active document and select nodes at different levels. You can click an individual node, use Ctrl or Cmd while clicking to add or remove nodes, or use Shift to select consecutive nodes.
The Filter nodes… box is useful for narrowing the visible hierarchy, but typing a filter does not select matching nodes immediately. Press Enter to select the matches. Keep that distinction in mind when a result appears filtered but the selection has not changed.

Replace a broad name match with a precise query
Suppose you want lysine residues. Typing LYS and pressing Enter can match more than the residues themselves: backbone and side-chain nodes may also have names containing LYS. The selection summary can help reveal the mismatch. The documented example has five LYS residues but fifteen selected nodes, because related nodes were included too.
To target the residue type instead, enter residue.type LYS in the filter and press Enter. The shorter equivalent is r.t LYS. This expression specifies that the node should be a residue and that its type should be LYS, making the intended selection more explicit than a text search.

After selecting, check the selection summary at the bottom of the Document view. If the Inspector is open, it can also show details about the selected nodes. This quick verification is especially helpful before applying an operation to a selection.
Save a query you will use again
If you repeatedly need the same kind of selection, save the NSL expression as a selection filter. Open Select > Find, or use Ctrl/Cmd + F, enter the expression, and click Save. Give the filter a clear name so it is easy to identify in the selection-filter list. For example, the expression r.t LYS or r.t HIS can be saved with a name such as LYS and HIS residues.

Custom filters can be removed by making one active and right-clicking the selection-filter list. The reset option removes all custom selection filters, so use it only if you intend to clear them all.
Keep selection level in mind
NSL expressions are useful for finding nodes, while the viewport selection filter controls the node level used by the rectangle selection editor and some other editors. For example, with the selection filter set to Residues, clicking an atom in the viewport selects at the residue level. The filter also affects Select all: with Atoms selected, it selects atoms; with Residues, it selects residues.
For selections you want to revisit quickly, Quick Groups offer another useful step: assign a selection with Shift plus a number, then press that number to switch back to it. A simple workflow might keep a ligand, receptor, and water selection in separate numbered groups while you work.
The main habit is simple: use a name search to find text, use an NSL expression when the node type or property matters, and check the selection summary before acting. For more selection methods and examples, see the SAMSON selection documentation.
Note: SAMSON and all SAMSON Extensions are free for non-commercial use. Get SAMSON.
