When working on large biomolecular systems in SAMSON, it’s often hard to focus on exactly the parts that matter. Whether you’re setting up simulations, analyzing a protein-ligand interaction, or identifying regions of interest in a macromolecule, the ability to filter residues based on precise criteria can save hours of manual work.
Fortunately, SAMSON’s Node Specification Language (NSL) supports a wide set of residue-level attributes that let you select what you need with clarity and control. In this post, we’ll introduce you to these residue attributes and explain how they can be combined for efficient filtering—so you can spend more time modeling and less time clicking.
Why residue filtering matters
Let’s say you want to:
- Select terminal residues for capping reactions.
- Focus on residues with a polar side chain in a binding pocket.
- Remove incomplete residues that could interfere with a simulation.
- Highlight charged amino acids in a protein surface visualization.
Each of these use cases requires inspecting the molecule at the residue level. Instead of doing this manually, NSL lets you write short expressions like:
|
1 2 3 4 |
r.ter # Select terminal residues r.p polar # Select amino acids with polar side chains not r.caab # Select residues with incomplete backbones r.c pos # Select residues with a positive side chain charge |
Overview of available residue attributes
Residue attributes in NSL fall into several categories:
- General properties:
r.n(name),r.ter(terminal),r.id(residue sequence number) - Chemical characteristics:
r.fc(formal charge),r.pc(partial charge),r.pKa1,r.pI - Classification:
r.aa,r.na,r.dna,r.rna - Structure-related:
r.caab(complete backbone),r.ss(secondary structure) - Properties consistent across residue types:
r.c(charge),r.p(polarity)
Combining filters
You can combine multiple filters for granular control. For example:
|
1 2 3 |
r.aa and r.p basic and r.ter # Basic amino acids that are terminal not r.caab and r.ss h # Incomplete backbone in alpha helix r.c neg and r.p polar # Negatively charged polar residues |
Each filter expression behaves like a query over the structure graph. You can use them for selection, coloring, measurement, and more. The r. prefix scopes your filter to residues, avoiding confusion with atomic or node-level attributes.
Use case: Identifying problematic residues before a simulation
Before launching a simulation, it’s helpful to identify incomplete or non-standard residues that might cause errors. You can try:
|
1 |
not r.caab or r.nsrn |
And to isolate standard amino acids with complete backbones and defined charges, you can use:
|
1 |
r.aa and r.caab and r.c pos, neg, neu |
Filter smarter, not harder
Memorizing a few of these short attributes can dramatically speed up your workflow. You no longer need to tediously click through residues—just declare what you want to see. The full list of attributes is documented, and their meanings and short names are intuitive once you start using them.
Learn more about residue attributes in NSL here →
SAMSON and all SAMSON Extensions are free for non-commercial use. You can get SAMSON at https://www.samson-connect.net.
