A crowded molecular project can turn a simple question—“Which folder contains the structure I need?”—into a slow tour through the document tree. You may be looking for a large structure, a particular number of chains, or a folder whose total charge falls in a useful range. SAMSON’s Node Specification Language (NSL) lets you search folders by these properties, so you can narrow the list before inspecting structures one by one.
The key idea is to search at the folder level. The folder attribute space matches folder nodes, and its short name is f. Many folder attributes describe the contents of the structure associated with that folder: atom counts, chain counts, residue counts, and total charge. The query examples below use the short form, which keeps searches compact.
Start with the size of the structure
If the first task is to separate small structures from larger ones, use numberOfAtoms, abbreviated nat. For example, f.nat > 100 matches folders whose structures contain more than 100 atoms. To focus on a narrower size band, use a range such as f.nat 100:200.
This can be a practical first pass when a project contains many structures and you already know roughly how large the target should be. It does not identify a structure by itself; it reduces the set of folders you need to examine.
Use counts that match the question
Atom count is only one way to describe a structure. If the number of chains matters, try f.nc < 3 for folders with fewer than three chains, or f.nc 2:4 for a range. For molecule counts, the corresponding attribute is f.nm; for example, f.nm 2:4 searches for folders with between two and four molecules.
When working with biomolecular structures, residue count may be more informative than total atom count. The attribute f.nr can target folders with more than 100 residues using f.nr > 100, or a range using f.nr 100:120. Other useful counts include segments (f.ns), structural groups (f.nsg), and structural models (f.nsm). For instance, f.nsm > 4 matches folders with more than four structural models.
Filter by composition or charge
Folder attributes also include counts for selected elements: carbons (f.nC), hydrogens (f.nH), nitrogens (f.nN), oxygens (f.nO), and sulfurs (f.nS). A query such as f.nO 10:20 looks for folders whose structures have between 10 and 20 oxygen atoms. These counts can help you narrow a search when you know something about the composition but do not remember the folder name.
For charge-based searches, use f.fc for total formal charge or f.pc for total partial charge. For example, f.fc 6:8 targets folders with formal charge in the stated range, while f.pc 1.5:2.0 targets a partial-charge range. These are folder-level totals, not atom-by-atom charge searches.
Keep the search readable
A useful approach is to begin with one property you trust—perhaps residue count or chain count—then refine your search using another relevant property. The examples here show individual expressions; consult the NSL reference for the language’s broader expression syntax when you want to combine criteria. You can also use inherited node attributes: f.n "A" searches by name, while f.v and f.h refer to visibility and hidden state. The full names are available too, which can be easier to read when sharing a query with a colleague.
These filters are most helpful when you treat them as a way to reduce browsing, not as a substitute for checking that a structure is scientifically appropriate. A matching atom count or charge is a useful clue, but it is not a complete description of a model.
For the complete list of folder attributes and examples, see the SAMSON folder attributes reference.
Note: SAMSON and all SAMSON Extensions are free for non-commercial use. Get SAMSON.
