slide1 n.
Skip this Video
Download Presentation

Loading in 2 Seconds...

play fullscreen
1 / 1

W0049 - PowerPoint PPT Presentation

  • Uploaded on

Citations DeLano, W.L. The PyMOL Molecular Graphics System (2002) on World Wide Web

I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
Download Presentation

PowerPoint Slideshow about 'W0049' - chava-snyder

Download Now An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.

- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript


DeLano, W.L. The PyMOL Molecular Graphics System (2002) on World Wide Web

Roger Sayle and E. James Milner-White. "RasMol: Biomolecular graphics for all", Trends in Biochemical Sciences (TIBS), September 1995, Vol. 20, No. 9, p. 374.Herbert J. Bernstein, "Recent changes to RasMol, recombining the variants, Trends in Biochemical Sciences (TIBS), September 2000, Vol. 25, No. 9, pp. 453-455.

C. Westin, B. Hanson, H.J. Bernstein, I. Awuah Asiamah, D. Boycheva, G. Darakev, J. Jemilawon, N. Jia, P. Kamburov, G. Todorov, P.A. Craig, S. Mottarella, "SBEVSL: Communicating Scripts Between Molecular Visualization Programs", poster presentation TP172 at the 2007 Meeting of the American Crystallographic Association (ACA 2007), 21-26 July 2007, Salt Lake City, UT, abstract E0003.

PDB ID: 1d66

Marmorstein, R., Carey, M., Ptashne, M., Harrison, S.C. (1992) DNA recognition by GAL4: structure of a protein-DNA complex. Nature 356: 408-414

  • Acknowledgements
  • NIGMS grant #1R15GM078077
  • Dowling College
  • H. J. Bernstein, G. Darakev, N. Darakev, J. Jemilawon,
  • G. McQuillan, G. Todorov, C. Westin
  • RIT College of Science

A RasMol to PyMOL Translator

Scott Mottarella, Brett Hanson, Charles Westin, Paul Craig, Herbert Bernstein

Biological Sciences, Rochester Inst. of Technology, 85 Lomb Memorial Dr., Rochester, NY 14623 USA.


For many educators and scientists, PyMOL is the application of choice for preparing images and animations of their structures because of the beauty and quality of the images. However, many are most familiar with the scripting languages associated with RasMol, Chime and Jmol. The long-range goal of our Structural Biology Extensible Visualization Scripting Language project is to make the multiple molecular visualization tools available to the broadest possible audience, where each user can use many programs, with knowledge of the scripting language for only one of those programs. The first step has been a comparison of the command sets for RasMol and PyMOL, followed by creation of a plug-in for PyMOL that will accept RasMol script files, translate the commands into PyMOL script and execute the commands. The process involves searching for recognized, valid, RasMol script commands and performing its PyMOL equivalent, either as a single command or as a series of commands that produce the same result. Future plans include expansion to additional molecular visualization programs and the preparation of a web site to provide script translation among the various programs. The project is funded in part by NIGMS grant #1R15GM078077.










The SBEVSL library will contain molecular visualization commands compatible with Universal Modeling Language (UML). Scripts from each program on the left will be converted to SBEVSL commands, which can then be output to any of the programs on the right. Each line in the diagram represents a module that translates the script from that program into a command from the SBEVSL Library, which will then translate the script to a desired scripting language. The ultimate goal is to allow any user to start at any scripting language, including SBEVSL, and to translate any script to any other scripting language.



##------------View Options----------------##

selectDict = {'wireframe': 'lines', 'cartoon': 'cartoon', 'dots': 'dots', 'cpk': 'spheres',

'spacefill': 'spheres', 'trace': 'ribbon', 'ribbon': 'ribbon'}

firstword = p.split( ' ', 1 )[0].lower()


if firstword in selectDict:

q = p + ' '

command = q.split( ' ', 1 )[1][:-1].lower()

if command=='false' or command=='off':

cmd.hide( selectDict[firstword], selected)

print firstword + ' off complete'

elif command=='true' or command=='on' or command=='': selectDict[firstword], selected)

print firstword + ' on complete'


print 'That function is not supported by PyMOL'


print 'An error has occurred with your view command.

Please check your spelling in your command,

the selection on which this command was executed

and that your command is supported by PyMOL.'

We utilized a variety of coding methods to correlate RasMol commands to their PyMOL command equivalent. When a single command could be directly translated, we used simple code to recognize that command and perform its equivalent, as in the Zap/Reinitialize example below (left). In some cases, however, more parameters needed to be handled, and so were broken into their constituents and handled individually, as in the Define example below (right). In yet one more case, several different commands with similar parameters could all be handled simultaneously using a Python dictionary object. See the View Options example to the right.


There are almost one hundred molecular visualization tools available today. They range in cost, complexity, and quality. What is concerning is that each program is more or less independent of all others. Two individuals using two different molecular visualization programs on the same project will not be able to communicate their views directly because each program has its own scripting language. Also, an individual who wishes to use multiple programs must learn a separate language for each program. The SBEVSL project is developing a universal scripting language compatible with the most popular molecular visualization programs. The first step is the creation of ConSCRIPT, the first script converter developed, which allows users to read RasMol scripts directly in PyMOL.


if p=='zap':

print 'reinitialize'



if p[:6]=='define':

defparams = p[7:].split( ' ', 1 ) defparams[0], select(defparams[1]) )

UserDefinedGroups[ defparams[0] ] = defparams[1]




cmd.load( "C:\Documents and Settings\Scotthew.

KYLE\Desktop\\1D66.pdb" )

cmd.rotate( 'x', 180 ) 'resn asp+glu+arg+lys+his+asn+thr+


met+trp+phe+pro and chain a' ) 'cartoon', 'sele' )

cmd.color( 'yellow', 'sele' ) 'All and chain b' )

cmd.color( 'purple', 'sele' ) 'dots', 'sele' )

cmd.hide( 'everything', 'all and not resn asp+glu+


gly+ala+leu+val+ile+met+trp+phe+pro' )

cmd.rotate( 'z', -90 ) 'id 1' )

cmd.color( 'green', 'sele' ) 'spheres', 'sele' )

load C:\Documents and Settings\Scotthew.


Select protein and :a


color yellow

select *:b

color purple


restrict protein

rotate z 90

select atomno = 1

color green



  • PyMOL Image
  • Clear image
  • Nice shadows and 3D effects
  • Clean depiction
  • (notice the dots)
  • RasMol Script
  • Reads like English
  • Easy to learn
  • Simple to execute
  • PyMOL Image From a RasMol Script
  • Quality image of PyMOL
  • Simple script of RasMol
  • No differences caused by ConSCRIPT
  • RasMol Image
  • Lower quality
  • Limited 3D effects
  • Low res dots
  • PyMOL Script
  • If it looks like computer code, it is
  • Difficult to read and understand
  • Must spell out the entire selection


ConSCRIPT is the first translator to be developed as part of the SBEVSL project. As shown here, it accurately converts given RasMol scripts into PyMOL scripts and is able to give the exact same output as any experienced RasMol user would expect, except with the higher quality images of PyMOL. The method for conversion is simple: create a dictionary class object to relate every known RasMol command to its PyMOL command equivalent. From ConSCRIPT, with the development of SBEVSL, we will be able to change the code to get similar converters from RasMol into SBEVSL and from SBEVSL into PyMOL, providing the same exact function as ConSCRIPT, but allowing for many other scripting languages to be easily included. Our next project is to convert Jmol scripts into PyMOL and then PyMOL and RasMol scripts into Jmol. From there, we will move towards unifying more molecular visualization scripting languages.

ConSCRIPT is available at:

This figure shows a selection of commands that work with ConSCRIPT. On the left are the RasMol commands and on the right are their equivalents in PyMOL.