I am new to pymol and python.  I have a number of cross
sections of lysozyme.  I want to display them one by one,
color them using a script file that I have written earlier,
and save the image.  I have written a script file that I had
hoped would do this.  I have a couple problems with script
file, but the one that is frustrating me the most is that
immediately after the beginning of for loop pymol says that
there in an unexpected EOF.  The other problem is that when I
try to use the variable pdb, pymol does not use the value of
the variable, but the variable name itself.  I have pasted my
script file below and part of the log file.

from pymol.cgo import *
import colorsys,sys,re
from pymol import cmd

z=-8.153
inc=0.5
Sections=100
for j in range(0, Sections):
     
pdb="c:/Users/jouko/Desktop/Research/Lysozyme/DensityCube_Lysozyme2-4a/DensityCube_Lysozyme2-4a_"
+ str(z) + ".pdb"
      load pdb
      @c:/b_color8.plm
      png pdb
      delete pdb
      z=z+inc


PyMOL>@c:/Users/jouko/CrossSections.plm
PyMOL>from pymol.cgo import *
PyMOL>import colorsys,sys,re
PyMOL>from pymol import cmd
PyMOL>z=-8.153
PyMOL>inc=0.5
PyMOL>Sections=100
PyMOL>for j in range(o, Sections):
Traceback (most recent call last):
 File "C:\Program Files\DeLano
Scientific\PyMOL/modules\pymol\parser.py", line 256, in parse
   exec(layer.com2+"\n",self.pymol_names,self.pymol_names)
 File "<string>", line 1
    for j in range(o, Sections):
                                ^
SyntaxError: unexpected EOF while parsing
PyMOL>pdb="c:/Users/jouko/Desktop/Research/Lysozyme/DensityCube_Lysozyme2-4a/DensityCube_Lysozyme2-4a_"
+ str(z) + ".pdb"
PyMOL>load pdb
ExecutiveProcessPDBFile-Error: Unable to open file 'pdb'.

Thanks in advance for your advice.


Jouko

------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge  
This is your chance to win up to $100,000 in prizes! For a limited time, 
vendors submitting new applications to BlackBerry App World(TM) will have 
the opportunity to enter the BlackBerry Developer Challenge. See full prize 
details at: http://p.sf.net/sfu/blackberry
_______________________________________________
PyMOL-users mailing list (PyMOL-users@lists.sourceforge.net)
Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users
Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net

Reply via email to