RasMol
RasMol is an open-source molecular graphics program designed for the interactive visualization and analysis of biological macromolecules, including proteins, nucleic acids, and small molecules.[1] Originally developed by Roger Sayle in 1993 as a tool for rendering molecular structures in various styles such as wireframes, space-filling spheres, and ball-and-stick models, it supports multiple platforms including Microsoft Windows, Apple Macintosh, UNIX, and VMS systems.[2][3] The software enables users to manipulate molecular orientations, apply color schemes based on properties like secondary structure or temperature factors, and generate publication-quality images, making it particularly valuable for teaching and research in structural biology.[1] RasMol's development began in the late 1980s when Sayle, as an undergraduate at Imperial College London, explored algorithms for depth perception and fast sphere-shadowing in molecular rendering.[3] During his graduate work at the University of Edinburgh from 1990 onward, he refined the program to achieve efficient single-processor performance, leading to its public release in 1993 shortly after his Ph.D. completion.[3] Supported initially by Glaxo Research and Development, early versions like 2.1 (1993) and 2.6 (1995–1996) were distributed freely to the scientific community, rapidly gaining popularity with over a million users by the late 1990s due to its accessibility and speed.[2][3] Following Sayle's primary development until around 2000, the project transitioned to open-source under the GNU General Public License in 2000, with Herbert J. Bernstein taking a leading role in the 2.7 series.[4] Key enhancements in this era included support for Crystallographic Information Files (CIF/mmCIF), Ramachandran plots, and stereo viewing, culminating in stable releases like version 2.7.4.2 in 2008, 2.7.5.1 in 2009, and 2.7.5.2 in 2011.[2][5] Contributions from developers such as Marco Molinaro, Arne Mueller, and Andreas Bohne expanded its scripting language, which influenced derivative tools like Chime and Jmol.[2][4] Despite its age, RasMol remains influential in molecular visualization, having democratized access to 3D structural analysis before the web era and serving as a foundational program in bioinformatics education.[3] Its command-line interface, while powerful for batch processing and automation, has been noted for a steeper learning curve compared to modern graphical alternatives, though it excels in rendering efficiency on resource-limited systems.[4] The program's legacy persists through maintenance by volunteer communities as of 2011 and its integration into broader workflows for exploring atomic coordinates from databases like the Protein Data Bank.[2]Introduction
Overview and Purpose
RasMol is a molecular graphics program designed for the visualization of three-dimensional structures of proteins, nucleic acids, and small molecules. Originally developed by Roger Sayle in 1992 while at the University of Edinburgh's Biocomputing Research Unit, it enables users to render and manipulate molecular models on personal computers, making complex structural data accessible without specialized hardware.[6] The primary purpose of RasMol is to facilitate the display, teaching, and exploration of molecular structures in structural biology and related fields. It supports the generation of publication-quality images and interactive sessions, allowing educators and researchers to demonstrate molecular features such as secondary structures, binding sites, and conformational changes. By providing tools for rotating, zooming, and selecting molecular components, RasMol aids in understanding spatial relationships and functional implications of biomolecules.[6][7] Widely adopted since its inception, RasMol has served hundreds of thousands of users globally, including scientists, students, and developers, due to its simplicity and effectiveness in educational and research environments. Its open-source evolution under the GNU General Public License from version 2.7.3 onward has further extended its accessibility and customization potential.[6]Applications in Structural Biology
RasMol has been a cornerstone tool in structural biology for the interactive visualization and analysis of three-dimensional biomolecular structures, particularly those derived from the Protein Data Bank (PDB). It enables researchers to load atomic coordinates of proteins, nucleic acids, and small molecules, rendering them in various styles to facilitate the interpretation of structural data obtained from techniques such as X-ray crystallography, nuclear magnetic resonance (NMR) spectroscopy, and cryo-electron microscopy. This capability allows structural biologists to examine molecular architectures, identify key features like folding patterns and residue interactions, and generate high-quality images for publications, with hundreds of thousands of users worldwide relying on it for such purposes.[6][8] In research applications, RasMol supports diverse visualization techniques tailored to specific analytical needs, such as wireframe models for tracing backbone connectivity, space-filling representations to assess molecular surfaces and van der Waals interactions, and ribbon diagrams to highlight secondary structures like alpha-helices and beta-sheets. For instance, these representations aid in studying enzyme active sites or ligand-binding pockets by coloring atoms based on properties like hydrophobicity or electrostatic potential, enabling quick identification of functionally relevant regions without extensive computational overhead. Additionally, RasMol's scripting language allows customization for batch processing, such as superimposing multiple structures to compare conformational changes across protein variants or NMR ensembles, which has been integral to investigations of dynamic biological processes.[8] RasMol has been integrated with structural biology workflows, including early web servers for advanced analyses like protein superposition and interaction detection. For example, the 3dSS server (2006) interfaced with RasMol to visualize superposed 3D structures including conserved water molecules, helping researchers evaluate structural alignments and evolutionary conservation. Similarly, servers like COLORADO3D (2004) and NCI used RasMol to display colored protein coordinates highlighting non-canonical interactions or evolutionary signals, supporting studies on protein-ligand binding and unusual structural motifs. These applications underscore RasMol's efficiency as a lightweight viewer for rapid prototyping and validation of hypotheses in structural research.[9][10][11] Despite the emergence of more advanced software, RasMol continues to be used in structural biology, particularly in educational settings, due to its simplicity, cross-platform compatibility, and low resource demands as of the early 2010s. Its open-source evolution has sustained its relevance, with variants enabling enhancements for modern datasets while preserving core functionalities for everyday structural exploration. Its influence persists through forks and derivatives that extend its legacy in bioinformatics.[12][2]History
Development and Initial Release
RasMol was initially developed by Roger Sayle as a final-year undergraduate project in 1989 at Imperial College London, where he focused on parallel algorithms for molecular graphics, particularly ray-tracing techniques to render shadowed space-filling molecular models efficiently.[13] The program's name, RasMol, derived from "RASter MOLecules," reflecting its emphasis on raster-based rendering with shadows, and coincidentally matched Sayle's initials. During his subsequent PhD at the University of Edinburgh under Dr. Andrew Coulson, Sayle further refined RasMol, optimizing its performance for UNIX workstations and incorporating user-requested features such as color-coded atoms, wireframe representations, and interactive rotations, evolving it from a research prototype into a practical visualization tool over approximately four years.[13] The initial public description of RasMol occurred in 1992, when Sayle presented it at the 10th Eurographics UK conference alongside co-author A. Bissell, highlighting its fast realistic rendering capabilities for molecular structures, including shadows, which allowed for high-quality visualizations on standard hardware without sacrificing interactivity.[14] This marked RasMol's debut as a freely available molecular graphics program, initially distributed for UNIX and PC platforms, and it quickly gained traction among structural biologists for its speed and simplicity in displaying protein and nucleic acid structures from coordinate files. The first public release, placing the source code on the internet, occurred in June 1993 with version 2.0, which included an optional $40 donation request to support development, followed by more frequent updates every few months.[2][13] In June 1993, as Sayle transitioned from academia, he placed RasMol into the public domain, making its source code freely available on the internet to encourage widespread adoption and contributions, a move that propelled its distribution to over 10,000 global sites by 1995.[13] This open release solidified RasMol's role as an accessible tool for molecular visualization, particularly in resource-limited environments, and laid the groundwork for its evolution into a cornerstone of structural biology software. In January 1994, Sayle joined Glaxo Research and Development (later GlaxoWellcome), where corporate support enabled further enhancements, including the first Macintosh port later that year.[13][3]Licensing and Open-Source Evolution
RasMol's licensing began as a public domain model without formal restrictions in its early versions. Developed by Roger Sayle, the initial release of RasMol 2.1 in 1993 and subsequent updates up to version 2.6 in the late 1990s were made freely available, allowing widespread adoption in academic, research, and corporate settings with only basic attribution requested.[2] This approach facilitated rapid dissemination but lacked mechanisms to ensure source code availability or collaborative development. The transition to a structured open-source licensing occurred with the RasMol 2.7 series, initiated in 1999 by contributors including Arne Mueller and Herbert J. Bernstein, who incorporated enhancements such as improved file format support. These versions introduced the RASMOL license (RASLIC), a custom open-source agreement that required distributors to include original documentation, credit authors, and share any modifications, while prohibiting binary-only releases.[2][15] This license, akin to the GNU General Public License (GPL) in promoting openness, addressed concerns over commercial exploitation by mandating source code transparency, though it initially avoided full GPL compatibility to resolve specific distribution issues.[16] In August 2000, the OpenRasMol project was established to centralize development of open-source RasMol variants, ensuring ongoing maintenance and preventing fragmentation.[6] A pivotal evolution came with RasMol 2.7.3 in 2005, which adopted a dual-licensing model allowing distribution under either the GPL or the RASMOL license.[15][16] This change broadened accessibility, enabling commercial use compliant with open-source principles, such as including source code and notices, while fostering contributions like advanced surface rendering. Subsequent releases, including 2.7.5 in 2009 and 2.7.5.2 in May 2011, continued under this framework, solidifying RasMol's role as a community-driven tool in structural biology visualization. The 2.7 series culminated with version 2.7.5.2 in May 2011, incorporating final enhancements such as improved surface rendering and interface updates. As of 2025, RasMol continues to be maintained by the OpenRasMol community without major new releases.[6][5]Features
Visualization Techniques
RasMol provides a range of visualization techniques for rendering three-dimensional molecular structures, enabling users to display proteins, nucleic acids, and small molecules in various representational styles. These techniques support interactive manipulation, including rotation, translation, zooming, and z-clipping, primarily through mouse controls, command-line inputs, or hardware dials. The program's core strength lies in its ability to overlay multiple display modes on different molecular components simultaneously, facilitating detailed analysis of complex biomolecular assemblies.[17] Key display representations include wireframe, which renders bonds as simple lines or depth-cued vectors for a skeletal view of connectivity; sticks, depicting bonds as thick cylinders in a "Dreiding" style for enhanced visibility of bond geometry; and spacefill, portraying atoms as solid spheres scaled to van der Waals radii (e.g., adjustable to 1.2 Å with a radius factor of 300). For proteins, backbone traces connect alpha carbons with lines or ribbons, while cartoon and ribbon modes illustrate secondary structures—such as alpha helices as coiled ribbons and beta sheets as flat arrows—with customizable widths (default 380 units for helices) and depths to highlight folding patterns. Nucleic acids are visualized similarly, often with strands or traces emphasizing base pairing and helical turns, and dots generate a dotted van der Waals surface (density adjustable from 1 to 1000 points) to approximate molecular envelopes.[17][18] Coloring schemes enhance interpretive power, with predefined options like CPK (assigning standard atomic colors, e.g., carbon in gray [200,200,200]) for elemental identification, amino or shapely for residue types (e.g., aspartic acid in red [230,10,10]), chain for distinguishing subunits, temperature for B-factor gradients (hotter colors for flexible regions), and structure for secondary elements (e.g., helices in red). Users apply colors via commands likecolour atoms cpk to specific objects such as atoms, bonds, labels, or hydrogen bonds, supporting RGB triples for custom palettes and propagation to neighboring atoms in maps. Alternate conformers or NMR models can be distinctly colored to compare dynamic states.[17][18]
Advanced rendering features include stereo viewing for 3D depth perception, enabled by the stereo command with adjustable eye separation (e.g., 3 degrees for cross-eyed viewing) and hardware support where available; depth-cueing to fade distant atoms for spatial context; and slab z-clipping modes (reject, half, hollow, solid, or section) to isolate molecular slices. Specular highlights and shadows add realism to spacefill and ribbon models, with ray-tracing options for shadows taking approximately 10 seconds for medium-sized proteins. Molecular surfaces, such as solid Lee-Richards solvent-accessible surfaces (introduced in version 2.7.3), can be generated with probe radii, alongside electron density maps from CCP4 or CIF files rendered as meshes, dots, or solids. These techniques collectively support high-fidelity visualization, with outputs exportable in raster (GIF, PPM) or vector (PostScript) formats for publications.[17][18][6]
Scripting and User Interface
RasMol provides a command-line interface for interactive control, where users enter commands at theRasMol> prompt in a dedicated terminal or console window, allowing real-time manipulation of molecular structures.[19] Commands support editing features such as command history recall (using up/down arrows or Ctrl+P/Ctrl+N) and auto-completion for certain options, facilitating efficient input up to 256 characters per line.[19] The interface emphasizes precision, enabling users to load molecules (load <filename>), select atoms (select <expression>), apply colors (colour <atom> <color>), and adjust views (rotate <axis> <angle>) directly via typed instructions.[20][21][22]
The graphical user interface consists of a primary display window with a default black background, resizable via window manager controls, and includes a menu bar offering options under categories such as File (for loading and saving), Display (for rendering modes like wireframe or spacefill), Colours (for palette management), Export (for image output), Options (for stereo viewing), and Settings (for font and axis adjustments).[23] Menus can be toggled on or off using the set menus [boolean] command, accommodating users who prefer a minimalistic view or full navigational aids.[24] Scrollbars along the window edges allow for basic panning and rotation, while the interface supports internationalization, displaying menus in languages like English, Spanish, or Russian if corresponding fonts are available.[25]
Mouse interactions form a core part of the user interface, configured by default in "RasMol" mode (set mouse rasmol), where the left button drags for X/Y rotation, the right button for X/Y translation, Shift+right for Z rotation, Shift+left for scaling (zoom), and Ctrl+left for slab clipping to focus on molecular slices.[26] Alternative modes like "Insight" mimic other software behaviors, with picking functionality enabled via set picking [ident|distance|angle] to identify atoms (displaying residue name, coordinates, and serial number) or measure interatomic distances and angles upon clicking.[27] For hardware integration, RasMol detects and utilizes dials boxes for analog control of rotation (X, Y, Z axes), zoom, and slab depth, enhancing tactile navigation on supported systems.[28]
Scripting in RasMol enables automation of complex visualizations by executing sequences of commands from text files, invoked via the script <filename> command or the -script <filename> command-line option, which processes the file line-by-line after loading any specified molecule.[29] Scripts support up to 10 levels of nesting and include control directives like pause (pausing for user keypress, synonymous with wait) to allow interactive interruptions, echo <text> for console output, and comments prefixed with #.[29] Ordinary commands such as zoom <percentage>, restrict <selection>, or show <element> can be sequenced for reproducible workflows, like animating rotations (rotate y 10 in a loop) or applying conditional selections based on atom properties.[30][31] To generate scripts from interactive sessions, users employ write script <filename> or write rasmol <filename>, capturing the current state and command history for reuse or documentation.[32]
Customization extends to initialization scripts, loaded automatically from files like .rasmolrc (Unix) or RASMOL.INI (other platforms) to set defaults such as background color (set background white), font size (set fontsize 12), or default rendering (set display [cpk](/page/CPK)).[33] Macros for reusable command blocks are defined with defer <name> <commands> and invoked via execute <name>, supporting parameterized scripting for tasks like batch coloring of residue types.[34] Inline scripts are possible using load inline followed by commands and terminated with exit, integrating directly into command-line workflows without external files.[20] These features collectively allow RasMol to balance immediate interactivity with scripted reproducibility, particularly in educational and research settings for structural biology.[18]
Technical Specifications
Platform Compatibility
RasMol was designed as a cross-platform molecular visualization tool, supporting a diverse array of operating systems and architectures from its inception in the early 1990s.[18] Early versions ran on various UNIX workstations, including SGI, Sun4, Sun3, Sun386i, DEC, HP, and E&S systems, as well as IBM RS/6000, Cray, Sequent, and DEC Alpha processors under OSF/1 or OpenVMS.[18] It also included support for VMS on VAX systems with DECwindows, alongside ports to Microsoft Windows (including Windows NT and Windows 3.1), Apple Macintosh, and PowerMac.[18][35] For UNIX and VMS environments, RasMol requires an 8-bit, 24-bit, or 32-bit color X Windows frame buffer (X11R4 or later), with optional support for hardware dials boxes and extensions like XInput or MIT-SHM for enhanced performance.[18] Additional operating systems such as OS/2, Linux, BSD386, and *BSD were accommodated in later releases, broadening its accessibility on IBM PCs and other desktop systems.[18] The open-source OpenRasMol project, which maintains RasMol (latest stable version 2.7.5, released July 2009), continues this compatibility with binaries for Microsoft Windows, Linux, and Mac OS X 10.5 (Universal Binary); source code is available for compilation on modern systems including recent macOS versions and BSD variants.[6][36] Specialized ports exist for niche platforms, such as RISC OS 3.1 or higher on Acorn 32-bit RISC computers, supporting display depths up to 24 bits per pixel.[16][37] This enduring cross-platform design has ensured RasMol's utility across academic and research environments spanning decades.[6]Supported File Formats
RasMol supports a range of input file formats for molecular structures and electron density maps, enabling the visualization of data generated by various computational chemistry and structural biology software packages. The primary input formats include the Protein Data Bank (PDB) format, which is the standard for atomic coordinates in structural biology; Tripos Associates' Alchemy and Sybyl Mol2 formats for molecular modeling data; Molecular Design Limited's (MDL) Mol format for chemical structures; Minnesota Supercomputer Center's XMOL XYZ format for Cartesian coordinates; CHARMm format for molecular dynamics simulations; J. P. Stewart's MOPAC output for quantum chemistry calculations; and IUCr's Crystallographic Information File (CIF) and macromolecular CIF (mmCIF) formats for crystallographic data. Additionally, RasMol can load electron density maps in CCP4 map format and imgCIF format.[17][18] For output, RasMol generates images and scripts in several raster and vector formats to facilitate publication and further processing. Supported output formats encompass GIF for web-compatible graphics; PPM and BMP for portable pixel maps; PICT for Macintosh graphics; Sun rasterfile for Unix systems; raster and vector PostScript for high-quality printing; MolScript input scripts for ribbon diagrams; and Kinemage for interactive 3D scenes. Maps can also be exported as imgCIF files using themap save command. These capabilities allow users to export visualizations directly from the program without additional conversion tools.[17][18]
| Category | Formats |
|---|---|
| Input (Molecular Structures) | PDB, Alchemy, Sybyl Mol2, MDL Mol, XMOL XYZ, CHARMm, MOPAC, IUCr CIF, IUCr mmCIF |
| Input (Electron Density Maps) | CCP4 map, imgCIF |
| Output (Images and Scripts) | GIF, PPM, BMP, PICT, Sun rasterfile, Raster PostScript, Vector PostScript, MolScript, Kinemage |
| Output (Maps) | imgCIF |
Interprocess Communication
Methods and Protocols
RasMol implements interprocess communication (IPC) to enable remote execution of commands, script processing, and data exchange between the application and other software processes, facilitating integration in computational workflows. This capability allows users to control RasMol instances programmatically, such as loading molecular structures, applying visualizations, or querying atomic data without direct user interaction. IPC is supported across major platforms, with platform-specific protocols ensuring compatibility and efficiency.[17] On X Windows systems, RasMol utilizes John Ousterhout's Tcl/Tk communication protocol for IPC. Upon startup, RasMol registers itself with the Tcl/Tk inter-application communication mechanism, typically as "rasmol", or "rasmol #2" and subsequent instances if multiple are running. Commands are sent to a specific RasMol instance using the Tclsend command, formatted as send {rasmol} {command}, where "command" is a valid RasMol instruction, such as background red to change the background color or load pdb 1crn to load a Protein Data Bank file. This protocol supports synchronous execution, allowing the sending process to wait for completion, and is particularly useful for embedding RasMol in larger Tcl/Tk-based environments or scripting automated visualization tasks. Error handling is managed through Tcl's return codes, with RasMol echoing results back to the sender if configured.[17]
Under Microsoft Windows, IPC is achieved via Dynamic Data Exchange (DDE), a standard Windows protocol for inter-application communication. RasMol, when compiled as RasWin, registers as the DDE application "RasWin" with topics such as "System" for basic controls or "RemoteControl" for advanced scripting. The protocol supports XTYP_EXECUTE requests to send RasMol commands, for example, via a DDE client like DDEInitiate("RasWin", "System"); DDEExecute("load pdb 1crn"); DDETerminate();. Additionally, DDE provides access to data items including "Name" for the current molecule, "Image" for bitmap export, "Pick" for selected atom details, and "Count" for atom/molecule tallies, enabling bidirectional data flow. This method is robust for integration with Windows applications like Microsoft Excel or custom tools, though it requires proper error trapping to handle cases like unregistered instances.[17]
For Macintosh systems, RasMol employs Apple Events as the IPC protocol, leveraging the Mac OS inter-application messaging framework. Events are sent to RasMol's process signature, typically "Rasm", using Apple Event Manager calls to dispatch commands or scripts. A common method involves the OpenDocument event with a file type "RSML", where dragging a script file onto the RasMol icon or sending an open event executes the contained commands sequentially, such as loading structures and applying rendering styles. This protocol supports high-level scripting similar to the other platforms but is tailored to Macintosh's event-driven architecture, allowing seamless interaction with tools like AppleScript for automation. Limitations include dependency on the Apple Event suite availability, which was standard in classic Mac OS versions supported by RasMol.[17]
Across platforms, IPC in RasMol enhances scripting by permitting external processes to pause execution with the pause command or suppress visual feedback using set hourglass off during remote command sequences, preventing cursor interruptions in long-running operations. These methods collectively enable RasMol's use in batch processing, educational demos, and integration with molecular modeling pipelines, though users must ensure command syntax compatibility to avoid protocol-level errors.[17]
Integration with Other Software
RasMol facilitates integration with other software primarily through platform-specific interprocess communication (IPC) protocols and a dedicated server mode, enabling remote control, data exchange, and visualization of molecular structures in collaborative workflows. On Microsoft Windows, RasMol employs Dynamic Data Exchange (DDE) to allow seamless interaction with applications such as Microsoft Word, Excel, and Visual Basic. For instance, DDE supports items like 'Pick' for real-time atom selection, where clicking an atom in RasMol triggers responses in linked applications, and 'Image' for exporting the current display as a Microsoft Device Independent Bitmap (DIB).[17] On Apple Macintosh systems, integration occurs via Apple Events, supporting core operations such as opening documents, printing, and quitting, often through script files with the 'RSML' type for automated execution.[17] For Unix and X Windows environments, RasMol leverages Tcl/Tk protocols, registering itself as a Tcl interpreter upon startup. This allows other Tcl-based applications, such as the 'wish' shell, to send commands directly; for example, the Tcl 'send' command can execute RasMol instructions like changing the display background to red viasend {rasmol} {background red}. Additionally, RasMol includes a TCP/IP server mode on port 21069, activated during compilation with the SOCKETS directive, which enables remote software to connect and issue command lines for interactive visualization of computational results from distant hosts. This mode processes inputs until an 'exit' or 'quit' command is received and can be tested using tools like telnet to the hostname and port.[38][17]
Beyond direct IPC, RasMol supports integration through output formats compatible with complementary molecular modeling tools. The 'write' command generates scripts for programs like Molscript (for ribbon diagrams), Mage (for kinemage stereographic projections), and POV-Ray (versions 2 and 3 for ray-traced rendering), allowing users to export scenes for further refinement or publication-quality images. Web browsers can also integrate RasMol via the 'load inline' command, embedding PDB coordinate data directly in HTML scripts for on-the-fly molecule loading and display. These mechanisms underscore RasMol's role as a modular component in broader bioinformatics pipelines, prioritizing command-line interoperability over graphical embedding.[38][39]