mdtraj.compute_chi2¶
- mdtraj.compute_chi2(traj, periodic=True, opt=True)[source]¶
Calculate the chi2 torsions of a trajectory. chi2 is the second side chain torsion angle formed between the corresponding 4 atoms over the CB-CG axis.
- Parameters:
traj (Trajectory) – Trajectory for which you want dihedrals.
periodic (bool, default=True) – If periodic is True and the trajectory contains unitcell information, we will treat dihedrals that cross periodic images using the minimum image convention.
opt (bool, default=True) – Use an optimized native library to calculate angles.
- Returns:
indices (np.ndarray, shape=(n_chi, 4)) – The indices of the atoms involved in each of the chi dihedral angles
angles (np.ndarray, shape=(n_frames, n_chi)) – The value of the dihedral angle for each of the angles in each of the frames.