It is.
----------
Pseudo code:
sel1 = u.select_atoms...
sel2 = u.select_atoms... # it is important to make the selection out of
the loop
for t in u.trajectory:
d = numpy.norm(sel1.center_of_geometry - sel2...)
----------
dihedral is somwhat more complex:
SEL = "resid %i and name %s"
C0 = SEL % (RESI-1, 'C')
N1 = SEL % (RESI, 'N')
CA = SEL % (RESI, "CA")
C1 = SEL % (RESI, "C")
N2 = SEL % (RESI+1, "N")
phiL = []
psiL = []
u = MDA.Universe(GRO, TRJ)
phi = sum([u.select_atoms(atom) for atom in [C0, N1, CA, C1]]).dihedral
psi = sum([u.select_atoms(atom) for atom in [N1, CA, C1, N2]]).dihedral
for f in u.trajectory:
phiL.append(phi.value())
psiL.append(psi.value())
On 9/4/20 9:02 AM, Baptiste Legrand wrote:
Hi all,
Is it possible to monitor distances, dihedrals etc. in a protein
trajectory? to finally plot distances or something else versus time.
(as VMD or others)
Thanks.
Best,
Baptiste
_______________________________________________
PyMOL-users mailing list
Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net
Unsubscribe:
https://sourceforge.net/projects/pymol/lists/pymol-users/unsubscribe
_______________________________________________
PyMOL-users mailing list
Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net
Unsubscribe:
https://sourceforge.net/projects/pymol/lists/pymol-users/unsubscribe