Least RMSD align#
Aligning structures with different topologies via sequence alignment and least-RMSD fitting.
The function molsysmt.structure.least_rmsd_align() superposes two macromolecular systems that may have different sequence lengths, point mutations, or topologies. It first conducts a sequence alignment to identify matching equivalent residues, and then executes a Kabsch least-RMSD spatial fit over the mapped atom pairs.
Added in version 1.0.0.
API documentation
Follow this link for a detailed description of the input arguments, raised errors, and returned objects of this function: molsysmt.structure.least_rmsd_align().
Basic usage#
Let’s show how to align two mutant variants of T4 lysozyme with different sequence lengths (PDB IDs: 181L with 162 residues and 1L17 with 164 residues):
import molsysmt as msm
molsys_1 = msm.convert('181l', selection='molecule_type=="protein"')
molsys_2 = msm.convert('1l17', selection='molecule_type=="protein"')
We inspect the sequences of both protein systems to observe the length discrepancy:
seq_1 = msm.convert(molsys_1, to_form='string:amino_acids_1')
seq_2 = msm.convert(molsys_2, to_form='string:amino_acids_1')
print(f'System 1 (181L) length: {len(seq_1)} residues')
print(f'System 2 (1L17) length: {len(seq_2)} residues')
System 1 (181L) length: 162 residues
System 2 (1L17) length: 164 residues
Sequence-guided structural superposition#
We superpose molsys_2 onto molsys_1 using molsysmt.structure.least_rmsd_align():
molsys_2_aligned = msm.structure.least_rmsd_align(molsys_2, reference_molecular_system=molsys_1)
print('Original center of system 2:', msm.structure.get_center(molsys_2))
print('Aligned center of system 2: ', msm.structure.get_center(molsys_2_aligned))
print('Reference center (system 1):', msm.structure.get_center(molsys_1))
Original center of system 2: [[[3.5281599388379186 1.1290532874617745 0.946882262996938]]] nanometer
Aligned center of system 2: [[[3.5028394190107877 1.127098545600861 0.9431480632093274]]] nanometer
Reference center (system 1): [[[3.4858737781225804 1.1384903801396447 0.9543625290923174]]] nanometer
See also
Related Tools & References
Convert: Convert molecular systems between different forms with
molsysmt.basic.convert().Get center: Calculate the center of mass or geometry with
molsysmt.structure.get_center().Get sequence alignment: Perform global pairwise sequence alignment with
molsysmt.topology.get_sequence_alignment().Least RMSD fit: Superpose systems with identical topology using the Kabsch algorithm with
molsysmt.structure.least_rmsd_fit().Get least RMSD: Calculate optimal superposition RMSD with
molsysmt.structure.get_least_rmsd().