Skip to content
Snippets Groups Projects
Commit 7032dc33 authored by BIOPZ-Johner Niklaus's avatar BIOPZ-Johner Niklaus
Browse files

Some cleaning in the helix_kink functions

parent ee1fddd4
No related branches found
No related tags found
No related merge requests found
...@@ -77,14 +77,14 @@ def AnalyzeHelixKink(t,sele,proline=False): ...@@ -77,14 +77,14 @@ def AnalyzeHelixKink(t,sele,proline=False):
""" """
This function calculates the bend,wobble and face-shift angles This function calculates the bend,wobble and face-shift angles
in an alpha-helix over a trajectory. The determination is more stable if in an alpha-helix over a trajectory. The determination is more stable if
there are at least 4 residues on each side (8 is even better) of the prolin around which there are at least 4 residues on each side (8 is even better) of the proline around which
the helix is kinked. The selection should contain all residues in the correct the helix is kinked. The selection should contain all residues in the correct
order and with no gaps and no missing C-alphas. order and with no gaps and no missing C-alphas.
Input: Input:
t : The trajectory to be analyzed (CoordGroup) t : The trajectory to be analyzed (CoordGroup)
sele : A selection containing the alpha helix to be analyzed (EntityView) sele : A selection containing the alpha helix to be analyzed (EntityView)
proline=False : An EntityView containing only the proline (or another residue) around which the proline=False : An EntityView containing only the proline (or another residue) around which the
helix is kinked. If False, the proline will be serached for automatically helix is kinked. If False, the proline will be searched for automatically
Output: Output:
(bend_angle,face_shift,wobble_angle) : a tuple of FloatLists (bend_angle,face_shift,wobble_angle) : a tuple of FloatLists
""" """
...@@ -104,9 +104,9 @@ def AnalyzeHelixKink(t,sele,proline=False): ...@@ -104,9 +104,9 @@ def AnalyzeHelixKink(t,sele,proline=False):
ca3_pos=ost.mol.alg.AnalyzeAtomPos(t,ca_3.GetHandle()) ca3_pos=ost.mol.alg.AnalyzeAtomPos(t,ca_3.GetHandle())
ca4_pos=ost.mol.alg.AnalyzeAtomPos(t,ca_4.GetHandle()) ca4_pos=ost.mol.alg.AnalyzeAtomPos(t,ca_4.GetHandle())
#Now we calculate the bend angle #Now we calculate the bend angle
bend_angle=[] bend_angle=ost.FloatList()
face_shift=[] face_shift=ost.FloatList()
wobble_angle=[] wobble_angle=ost.FloatList()
for i in range(n_frames): for i in range(n_frames):
bend_angle.append(__CalculateBendAngle(pre_proline_axis[i],post_proline_axis[i])) bend_angle.append(__CalculateBendAngle(pre_proline_axis[i],post_proline_axis[i]))
face_shift.append(__CalculateFaceShift(pre_proline_axis[i],post_proline_axis[i],pre_proline_centers[i],post_proline_centers[i],proline_pos[i],ca3_pos[i],ca4_pos[i],bend_angle[i])) face_shift.append(__CalculateFaceShift(pre_proline_axis[i],post_proline_axis[i],pre_proline_centers[i],post_proline_centers[i],proline_pos[i],ca3_pos[i],ca4_pos[i],bend_angle[i]))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment