Paul,

PyMOL is pretty good at this kind of thing and you can automate it at
various levels (eg. bash/shell script level, inside PyMOL using Python
commands, etc).  Let's say you have 100 poses in your ouput directory;
to do what you've asked, I'd try:

python
import glob
inFiles = glob.glob("output/*.pdb")
for f in inFiles:
  cmd.load(f, "current")
  cmd.zoom("org")
  cmd.zoom()
  cmd.show_as("surface", "poly")
  cmd.show_as("sticks", "org")
  cmd.png( f + ".png", f, ray=1, height=800, width=600)
  cmd.delete("current")
python end

This will write out 100 png files each just named with ".png" appended
to the PDB name, ray traced, and at 800x600 image size.

A couple other hints:
 (1) If it's the same protein over and over again, you can setup the
best view by hand, just once, and then do
  get_view()
  and restore that view in all other proteins
 (2) PyMOL has a preset view for ligand binding sites; A > Preset >
Ligand Sites > Transparent (better) is a good one.

Good luck,

-- Jason

On Thu, May 6, 2010 at 1:00 AM, Paul Rigor (uci-ics) <pri...@ics.uci.edu> wrote:
> Hi,
>
> Is there anyway to access the rendering engine of pymol through a
> command line script?
>
> I'd like to take a snapshot of a ligand-bound protein, but automate
> the view such that
> 1) The protein is shown as a surface
> 2) The view centers around the binding area
> 3) The view zooms out enough to present the entire protein
> 4) Produce a png or a brief video.
>
> Thanks in advance!
> Paul
>
> ------------------------------------------------------------------------------
>
> _______________________________________________
> 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
>



-- 
Jason Vertrees, PhD
PyMOL Product Manager
Schrodinger, LLC

(e) jason.vertr...@schrodinger.com
(o) +1 (603) 374-7120

------------------------------------------------------------------------------

_______________________________________________
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