[Chimera-users] Help in writing python code
aka895 at gmail.com
Fri Feb 6 09:34:22 PST 2015
Thanks. I got it.
On 06-Feb-2015 9:47 pm, "Elaine Meng" <meng at cgl.ucsf.edu> wrote:
> Hi Ankit,
> You would just use the “close” Chimera command to close the new axes model
> each time, e.g. “close #2” if the axes model is #2. You can see which one
> it is in the Model Panel (under Favorites in the menu). I would expect it
> to be the next unused number.
> Before actually running a script for a whole trajectory you should
> generally work out the necessary commands “by hand” (interactively) for one
> or two frames first.
> I hope this helps,
> Elaine C. Meng, Ph.D.
> UCSF Computer Graphics Lab (Chimera team) and Babbitt Lab
> Department of Pharmaceutical Chemistry
> University of California, San Francisco
> On Feb 5, 2015, at 8:53 PM, Ankit Agrawal <aka895 at gmail.com> wrote:
> > Hi
> > I am doing trajectory analysis which has 40000 frames. So for all frames
> I wanted to calculate the all three inertia axes. That I did. But problem
> is that when I run the python code it starts making all the three axes for
> each frames that becomes messy. So I want a little change in my code so
> that during trajectory analysis it should create axes but should delete or
> hide the previous axes also. So during run I will see only the axes which
> are related to that frame.
> > Here is the python code in per-frame analysis.
> > from chimera import runCommand
> > frame = mdInfo['frame']
> > runCommand("measure inertia #1:0-120 color yellow")
> > runCommand("measure inertia #1:120-237 color green")
> > Thanks.
> > Ankit
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Chimera-users