Text commands can be entered into VMD in several ways:
Commands can be entered by typing them at the VMD prompt in
the text console window. This window normally contains the prompt vmd > . When other text (e.g., from a mouse pick) is displayed to
the screen, it will scroll the screen up so the prompt is not at the
last line of the screen. To make it reappear, press enter. When
entering multi-line commands, an alternate prompt appears, ? ,
and will not disappear until the command is finished. Sometimes it is
waiting for a close to a double quote, open brace, or open bracket,
while at other times it is waiting for a line that doesn't end in a
Since you may not want to retype all the data in every time, there are
two ways to read the data in from a text file. One
is the play command. This reads a line from the file,
executes it, then updates the screen and checks for any changes in the
mouse or window input, so that VMD stays interactive during execution of
the script. The second way is the Tcl command source. This reads the whole file before allowing the
mouse and windows to respond to new input. This is often more efficient
when your script contains many lines.
On Unix/Linux platforms, if the file .vmdrc (see
section 14.3.3) exists in your home
directory, it is played at VMD startup. If you don't have a .vmdrc
file, VMD uses a default script in the VMD installation directory.
Similarly, at startup the -e command line flag can be used to specify
an input file to be played after reading the .vmdrc file.
The Windows version of VMD works similarly, though the startup file
is named vmd.rc.
A good use of the .vmdrc file is to specify which VMD menus you
would like to have open when you start VMD and where they should be placed;
see section 9.3.19) for information