Re: [PyMOL] MD analysis (distance, dihedral etc)
Thanks Tamas, I will have a look on this. Best, Baptiste Le 04/09/2020 à 15:55, Tamas Hegedus a écrit : 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 ___ 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
Re: [PyMOL] MD analysis (distance, dihedral etc)
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
[PyMOL] MD analysis (distance, dihedral etc)
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