geomm.superimpose.
superimpose
(ref_coords, coords, idxs=None, weights=None)[source]¶Superimpose a set of coordinates to reference coordinates using the Theobald-QCP method.
Assumes coordinates are centered appropriately.
ref_coords (arraylike) – The template coordinates that coords will be aligned to.
coords (arraylike) – The coordinates which will be aligned to the template coordinates and have the rotation matrix applied to them and returned.
idxs (arraylike, optional) –
alignment on this subset of atoms to the reference.
(Default = None)
weights (arraylike, optional) –
(‘center of mass’) used in translations to the origin and to the centroid of the reference structure.
(Default = None)
superimposed_coords (arraylike of float) – The transformed coordinates.
rotation_matrix (arraylike) – The rotation matrix from Theobald-QCP that minimized the RMSD
qcp_rmsd (float) – The RMSD calculated from Theobald-QCP.
Warning
Assumes that the coordinates are both centered.
geomm.superimpose.
alt_superimpose
(ref_coords, coords)[source]¶Returns the translation and rotation mapping mobile onto target.
mobile (ndarray, shape = (n_atoms, 3)) – xyz coordinates of a single frame, to be aligned onto target.
target (ndarray, shape = (n_atoms, 3)) – xyz coordinates of a single frame
translation (ndarray, shape=(3,)) – Difference between the centroids of the two conformations
rotation (ndarray, shape=(3,3)) – Rotation matrix to apply to mobile to carry out the transformation.