molsysmt.build.add_missing_terminal_cappings#
- molsysmt.build.add_missing_terminal_cappings(molecular_system, N_terminal=None, C_terminal=None, pH=7.4, keep_ids=False, selection='all', syntax='MolSysMT', engine='MolSysMT', skip_digestion=False)[source]#
Adding terminal cappings to peptides and proteins.
This function adds chemical groups to the N- and/or C-termini of protein or peptide chains. These terminal groups can either neutralize terminal charges or simply complete missing atoms for a standard terminal residue. The resulting cappings are consistent with typical protonation states at the specified pH.
- Parameters:
molecular_system (molecular system) – Molecular system in any supported MolSysMT format.
N_terminal (object, default=None) – Argument N_terminal.
C_terminal (object, default=None) – Argument C_terminal.
pH (object, default=7.4) – Argument pH.
keep_ids (object, default=False) – Argument keep_ids.
selection (str, list, tuple, or numpy.ndarray, default='all') – Selection string or boolean/integer array specifying elements.
syntax (str, default='MolSysMT') – Selection syntax used to evaluate selection (e.g., ‘MolSysMT’, ‘MDTraj’).
engine (object, default='MolSysMT') – Argument engine.
skip_digestion (bool, default=False) – Whether to skip MolSysMT’s internal argument digestion mechanism.
- Returns:
A new molecular system with modified termini, in the same form as the input system.
- Return type:
molecular system
- Raises:
NotSupportedFormError – Raised if the input molecular system is in a non-supported form.
ArgumentError – Raised if an input argument value is invalid.
Notes
- Common capping groups:
‘ACE’ for acetyl (N-terminal)
‘NME’ for N-methyl amide (C-terminal)
If no capping residues are provided, the function only completes missing terminal atoms in the native residues (which are often charged).
The native engine delegates nonterminal heavy-atom repair to its bounded placement tool. Unsupported side-chain gaps remain missing with
UnassessedResidueWarning, even if terminal completion succeeds. Inspectget_missing_heavy_atomsas well asget_missing_terminal_cappings. PDBFixer can choose additional reconstructions, so whole-system atom counts need not match between engines.Native atom expansion requires one selected chemical state. Existing atom assignments, state identity/provenance and observed coordinates survive. Added chemical fields remain unknown and connectivity is partial; capping geometry does not assign a complete chemical state. Existing atom IDs are retained, but inserted groups can change indices. Named interaction analyses retain their definitions and remapped axes while observations and evaluated coverage are cleared for recalculation. Unsupported structural attributes and force-field atom parameters are dropped with a diagnostic. Assign and validate the intended terminal chemistry separately before further preparation.
The list of supported molecular system forms is detailed in: User Guide > Introduction > Molecular systems > Forms
See also
molsysmt.build.build_peptide()Construct a peptide sequence with optional terminal cappings.
molsysmt.build.add_missing_heavy_atoms()Add missing non-hydrogen atoms to standard residues.
molsysmt.basic.info()Inspect the content and composition of a molecular system.
molsysmt.physchem.get_charge()Calculate the total or partial charge of a system.
Examples
>>> import molsysmt as msm >>> molsys = msm.build.build_peptide('AlaValPro') >>> molsys = msm.build.add_missing_terminal_cappings(molsys, N_terminal='ACE', C_terminal='NME') >>> msm.convert(molsys, to_form='string:amino_acids_3') 'AceAlaValProNme'
User guide
Follow this link for a tutorial on how to work with this function: User Guide > Tools > Build > Add missing terminal cappings
Added in version 1.0.0.