Working on molecular models often involves managing multiple chains, each with distinct attributes. For modelers striving to work more effectively with chains in the SAMSON integrative molecular design platform, understanding and leveraging chain-specific attributes can make a significant difference. In this post, we delve into these attributes within SAMSON’s Node Specification Language (NSL) and showcase how to use them efficiently to streamline your modeling process.
What Are Chain Attributes?
The chain attribute space (short name: c) in NSL is a dedicated space designed to match chain nodes. Whether you want to sort, organize, or filter chains based on their visibility, number of atoms, or chain ID, NSL’s granularity allows you to fine-tune your selections and operations easily. Attributes in this space inherit from node and structuralGroup attribute spaces, while also introducing several unique attributes specific to chains.
Leveraging Core Attributes
Let’s take a closer look at some of the essential attributes:
- Visibility: Using the
visible(c.v) attribute, you can filter chains that are currently visible (true) or hidden (false). Example:c.vto select all visible chains. - Selection: With attributes like
selected(c.selected) orselectionFlag(c.sf), you can target chains based on whether they are selected or flagged for selection.
Chain-Specific Attributes
What sets chain attributes apart are the unique identifiers exclusive to this space, enabling you to capture the core characteristics of each chain. Here are a few powerful examples:
- Chain ID: Using
chainID(c.id), you can access or filter chains by their unique chain IDs. Example:c.id 2:4matches chains with IDs 2 through 4. - Number of Residues: The
numberOfResiduesattribute (c.nr) allows filtering chains based on their residue count. Example:c.nr > 130selects chains with more than 130 residues.
Combining Attributes for Advanced Queries
One of the most powerful aspects of utilizing these attributes is the ability to combine them into complex queries. For instance, if you want to filter visible chains with more than 100 atoms and a chain ID below 3, your query could look like this:
|
1 |
c.v and c.nat > 100 and c.id < 3 |
This flexibility within NSL allows for precise control over which chains are targeted during modeling processes.
Inherited Attributes from Node and StructuralGroup
Chain attributes don’t stand alone—they inherit key properties from node and structuralGroup. Attributes like numberOfCarbons (c.nC) or formalCharge (c.fc) ensure you have molecular-level granularity for atom counts and charges.
Conclusion
Mastering chain attributes in SAMSON’s NSL unlocks a new dimension of precision and control in molecular modeling. Whether you’re working on a structural bioinformatics project, analyzing polymer chains, or refining molecular structures, the rich set of attributes in the chain space can save significant time and effort.
Explore the full documentation on SAMSON’s Node Specification Language and chain attributes here: https://documentation.samson-connect.net/users/latest/nsl/chain/.
Note: SAMSON and all SAMSON Extensions are free for non-commercial use. Discover the platform and get started today at https://www.samson-connect.net.
