This is a read-only mirror of pymolwiki.org

Difference between revisions of "Command Line Options"

From PyMOL Wiki
Jump to navigation Jump to search
(pymol --help 1.8.6)
m (1 revision)
 
(No difference)

Latest revision as of 04:31, 26 June 2017

PyMOL has lots of options for controlling it immediately from startup. Run 'help launching' from the command line for detailed listings of options for your current version of PyMol. Here is a sample output which should be pretty consistent for recent versions.

Command Line Options

shell> pymol --help
PyMOL 1.8.6.0 Incentive Product
Copyright (C) Schrodinger, LLC

Usage: pymol [OPTIONS]... [FILES]... [-- CUSTOM SCRIPT ARGUMENTS]

Options

  --help    display this help and exit
  --version display PyMOL version and exit
  --retina  use retina resolution (MacPyMOL) and set display_scale_factor=2

  -1        config_mouse one_button
  -2        config_mouse two_button
  -a N      alias for -A
  -A N      application configuration:
    -A1     simple viewer window          (-qxiF -X 68 -Y 100)
    -A3     internal GUI only, no splash  (-qx -X 68 -Y 100)
    -A4     used by PYMOLVIEWER           (-X 68 -Y 100)
    -A5     helper application            (-QxiICUF -X 68 -Y 100)
    -A6     full screen presentation      (-qxieICUPF)
  -b[N]     benchmark wizard
  -B        (DEPRECATED)
  -c        launch in command-line only mode for batch processing
  -C        don't terminate on Ctrl-C
  -d cmd    execute PyMOL command
  -D N      defer_builds_mode=N
  -e        full screen
  -E N      multisampling (GL_MULTISAMPLE_ARB)
  -f N      internal_feedback=N
  -F        internal_feedback=0
  -g file   save image (png) or movie (mpg)
  -G        game mode (DEPRECATED)
  -h        generic helper application (no controls, no feedback)
  -H N      window height in pixels
  -i        internal_gui=0
  -I        auto_reinitialize=1 (Mac only)
  -j        side-by-side stereo (stereo_mode=4)
  -J        cd to user's home directory
  -k        don't load pymolrc or plugins
  -K        keep alive: when running without a GUI, don't quit after the input
            is exhausted
  -l file   run python script in thread (spawn)
  -L file   load file after everything else (only if something was loaded before)
  -m        INTERNAL - do not use (mac external GUI)
  -M        force mono
  -n        INTERNAL - do not use (incentive_product=1)
  -N name   UNSUPPORTED - external gui type (default: pmg_tk) (same as -w)
  -o        disable security protections
  -O N      sphere_mode=N
  -p        read commands from STDIN
  -P        handle scenes as if the session were opened in presentation mode
  -q        supress startup message
  -Q        quiet, suppress all text output
  -r file   run python script
  -R        launch RPC Server
  -s file   log to file
  -S        force stereo
  -t N      stereo_mode=N
  -T name   UNSUPPORTED - Tcl/Tk GUI skin
  -u file   resume log file (execute existing content and append new log output)
  -U        UNSUPPORTED reuse the helper application
  -v        UNUSED
  -V N      external GUI window height in pixels
  -w name   UNSUPPORTED - external gui type (default: pmg_tk) (same as -N)
  -W N      window width in pixels
  -x        no external gui
  -X N      window x position on screen
  -y        exit on error
  -Y N      window y position on screen
  -z N      window_visible=N
  -Z N      zoom_mode=N

Supported File Formats

<file> can have one of the following extensions, and all files provided will be loaded or run after PyMOL starts.

PyMOL Supported File Formats
Extension Format
.pml PyMOL command script to be run on startup
.py, .pym, .pyc Python program to be run on startup
.pdb Protein Data Bank format file to be loaded on startup
.mmod Macromodel format to be loaded on startup
.mol MDL MOL file to be loaded on startup
.sdf MDL SD file to be parsed and loaded on startup
.xplor X-PLOR Map file (ASCII) to be loaded on startup
.ccp4 CCP4 map file (BINARY) to be loaded on startup
.cc1, .cc2 ChemDraw 3D cartesian coordinate file
.pkl Pickled ChemPy Model (class "chempy.model.Indexed")
.r3d Raster3D file
.cex CEX file (Metaphorics)
.top AMBER topology file
.crd AMBER coordinate file
.rst AMBER restart file
.trj AMBER trajectory
.pse PyMOL session file
.phi Delphi/Grasp Electrostatic Potential Map

Examples

# load the 3 pdb files and execte the following commands
pymol mol1.pdb mol2.pdb mol3.pdb -d 'as ribbon;spectrum count;set seq_view'

# load the 3 pdbs and run the script
pymol mol1.pdb mol2.pdb mol3.pdb my_script.pml

# Run my_program using PyMOL as the Python interpreter
# passing the 3 pdb files to my_program.py
pymol my_program.py -- mol1.pdb mol2.pdb mol3.pdb