Entering edit mode
7.7 years ago
ddhecnu
•
0
Hi everyone, I want to render images of frames of my trajectory that loaded in pymol with this script:
for i in range(1, cmd.count_states()+1):
cmd.set("state", i, "traj")
cmd.png("%d.png" % (i), width=10, height=10, dpi=300)
After running this script, pymol outputs images and they are all the same. So what's wrong with my script?
You can format code using the
101010
button, I edited your post for clarity. You can add aprint(i)
in your loop to check whether i is what it should be while looping.Thank you for you nice formating!