A molecular structure can contain thousands of atoms, but many modeling questions start with a much smaller one: which parts of the receptor are actually near the ligand? Finding that neighborhood by eye is slow, and a broad selection can bring in waters, hydrogens, distant residues, or other components that distract from the question.
In SAMSON, Node Specification Language (NSL) lets you describe a selection by both what nodes you want and where they are relative to other nodes. That makes it possible to build focused selections for contact inspection, pocket analysis, and clash screening. The examples below show a practical way to think about those selections: establish the molecular category, choose the level of detail, then add a distance condition.
Start with the ligand neighborhood
For a first pass, select receptor residues within 6 Å of the ligand, while excluding glycine and alanine:
|
1 |
((n.t r and not r.t GLY,ALA) in n.c rec) w 6A of n.c lig |
Read this from the inside out. n.c rec identifies the receptor category, and n.t r asks for residues. The residue-type condition removes GLY and ALA; the final w 6A of n.c lig restricts the result to the ligand’s spatial neighborhood. The point is not that 6 Å is always the right cutoff. It is that the cutoff and the biological question are visible in the expression, so you can adjust one without rebuilding a selection by hand.
If you need atoms rather than residues—for example, to inspect close contacts—change the selection level:
|
1 |
(n.t a in n.c lig) w 2A of n.c rec |
This finds ligand atoms within 2 Å of receptor nodes. A narrow cutoff can flag tight contacts worth checking, but distance alone does not establish that two atoms clash; interpretation depends on the atoms and the modeling context.
Make the selection answer a specific question
A useful selection is usually more than “everything near the ligand.” To focus on polar heavy-atom contacts, select receptor oxygen and nitrogen atoms within 3 Å:
|
1 |
(a.s O,N in n.c rec) w 3A of n.c lig |
To inspect ligand heavy atoms without hydrogens, combine a category selection with an exclusion:
|
1 |
(n.t a in n.c lig) and not a.s H |
These two expressions help separate a chemical question from a geometric one: first decide which atoms are relevant, then apply a distance threshold. That is especially helpful when an unfiltered contact list is too large to interpret.
Water can be treated as its own category. For example, find waters within 4 Å of the ligand:
|
1 |
n.c wat w 4A of n.c lig |
Or look for water oxygens within 3 Å of both receptor and ligand:
|
1 |
(a.s O in n.c wat) and (n.t a w 3A of n.c rec) and (n.t a w 3A of n.c lig) |
The second expression narrows the question to possible bridging waters. It is a geometric filter, not a verdict that a water is energetically important or should be retained. Treat the result as a shortlist for visual and chemical review.
Use exclusions to reduce noise
Exclusions are often as useful as inclusions. To find receptor atoms within 5 Å of the ligand while excluding atoms within 3 Å of water oxygens, the examples page gives:
|
1 |
(n.t a in n.c rec) and (n.t a w 5A of n.c lig) and (n.t a b 3A of (a.s O in n.c wat)) |
Here, w specifies a within-distance condition and b specifies a beyond-distance condition. A similar pattern can identify aromatic residues near a ligand but beyond 3 Å of water:
|
1 |
(r.t PHE,TYR,TRP,HIS w 5A of n.c lig) and (n.t r b 3A of n.c wat) |
These combinations are useful when you want to compare local environments—for example, a ligand-facing residue neighborhood with and without nearby water. Be precise about the node level in each part of an expression: an atom-level selection and a residue-level selection answer different questions, even when they use the same distance.
A small workflow for cleaner contact checks
- Choose the target: identify whether the result should contain atoms, residues, or another node type.
- Set the molecular scope: use categories such as receptor, ligand, and water to avoid mixing unrelated components.
- Add one distance rule: start with a threshold suited to the question, then refine it rather than stacking filters immediately.
- Exclude likely distractions: remove hydrogens, selected residue types, or water-proximal nodes only when that matches your analysis.
- Interpret, don’t overread: an NSL distance selection identifies geometric candidates. It does not by itself calculate binding strength, prove a hydrogen bond, or determine whether a contact is favorable.
This approach turns a crowded structure into a set of explicit, reusable questions: which residues are near the ligand, which atoms make close approaches, and which waters sit between components? For more selection patterns and syntax examples, see the NSL examples documentation.
Note: SAMSON and all SAMSON Extensions are free for non-commercial use. Get SAMSON.
