Running SAS®, SPSS, and BMDP on the Academic Zoo Cluster

The SAS System, SPSS, and BMDP are three of the most widely used programs for statistical analysis at UVM. All are available to any UVM affiliate with an account on the academic Zoo cluster. SAS and SPSS can be run in any one of five different modes of execution, depending on the user's hardware and/or on the user's personal preference. The five modes of execution are detailed below. BMDP can be run in four of the five modes of execution.

X Windows Interactive Mode

X Windows provides a graphical user interface to many applications running on Unix systems. SAS, SPSS, and BMDP can be run on an X terminal or from a microcomputer running an X server application. This is the mode of execution expected by default when you type "sas" or "spss" at the system prompt. To use BMDP with its X windows interface, type "xbmdp" at the system prompt. If your hardware is X Windows capable, you will be presented with a set of interactive windows, allowing you to navigate through the programs using a mouse. This mode of execution provides the highest level of interactivity with the programs, similar to that provided by running them on a Macintosh or in Microsoft Windows. Refer to the respective product manuals for information on how to proceed from here.

ASCII Terminal Interactive Mode

A graphical user interface is not necessary to run SAS or SPSS programs interactively. ASCII terminals can draw crude approximations of windows using the ASCII character set. This provides you with the ability to use SAS or SPSS interactively, but gives you no mouse capability. To run SAS and SPSS in this manner, the commands are, respectively:
   sas -fsdevice ascii.vt100

   spss +m
There is one major problem with this method of interactive use for SAS. SAS maps many commands to various keys on the VT100/VT220 keyboard. Most people run a terminal emulator on their microcomputer which emulates a VT100 or VT220 terminal. Since the software expects you to be using a VT100 or VT220 terminal, it also expects the keyboard to have certain keys in certain places. Terminal emulation programs vary in how they map the VT100/VT220 keyboard to the microcomputer keyboard. Thus, it is very difficult to determine the correct key to press for SAS to issue, for example, the SUBMIT command. This means that, for the most part, you must type each command you wish to give on the window's command line rather than pressing the appropriate key which SAS has mapped for this command.

BMDP has an interactive mode which is best described as partially an ASCII terminal interactive mode and partially an ASCII terminal line mode. It will be described briefly in the next section.

ASCII Terminal Line Mode

This mode of execution allows for interactive use, but instead of a window in which to interact with the program, a line prompt allows you to input commands one after another. Program output is displayed on your screen. The commands to invoke SAS and SPSS in this mode are as follows:
   sas -nodms

   spss -m
No output files are created when the programs are used in this manner. BMDP is invoked with the "bmdp" command, which then prompts you for the name of the BMDP program to run (2D, 2V, 1R, LR, etc.). It then prompts you for the name of a BMDP instruction file. If you press "Enter" without entering a file name, BMDP runs the program specified (2D, 2V, etc.) in interactive mode and invokes the BMDP editor which allows you to build a set of BMDP instructions, run them, and display the output on your screen.

Non-interactive Mode

All three statistical packages can be run in a non-interactive mode. The programs accept commands from a file, execute those commands, and place the results into an output file. You should have an existing file with a .sas, .sps or .bmd extension containing your commands. The file can be created by using a text editor such as pico or emacs or may be created by a word processor and transferred from your microcomputer. Data may be included in the same command file, or a separate data file may exist which is then referenced by the SAS, SPSS, or BMDP command file. Execution begins after issuing the following commands and ends when the system prompt returns.
   sas filename.sas

   spss -m filename.sps > filename.lst

   bmdp program_name filename.bmd filename.lst
SAS will read the commands in filename.sas and create two new files; one called filename.log containing SAS informational notes and error messages, and one called filename.lst containing the actual SAS procedure output. If filename.log and/or filename.lst already exist, SAS will automatically overwrite these files. SPSS will read the commands in filename.sps and redirect the output to filename.lst. If filename.lst exists and you have set the environment variable noclobber, the output file will not be overwritten. In order to overwrite the output file, you must issue the command unset noclobber at the system prompt before running SPSS. BMDP runs the specified program using the BMDP commands in filename.bmd and places the output in filename.lst. If you do not enter a program name, command file name, or output file name, you will be prompted for them.

Putting an ampersand (&) at the end of the above commands will allow the programs to run in the background while you continue working on your terminal. When the job is finished, a message is sent to your terminal.

Batch Mode

Batch execution is the preferred method if your SAS, SPSS, or BMDP job is likely to consume a great deal of CPU time. In order to run jobs in batch, you will need to have already created SAS, SPSS, or BMDP command files as described in the previous section. You should also create a file containing the commands you want the batch processor to execute. For example, if you want to run a SAS program in batch, put the command SAS filename.sas into a file called, say, run.batch. Make this file executable by typing chmod a+x run.batch. Then submit this file to the batch processor by typing:
   submit run.batch
at the system prompt. To find out whether you have any batch jobs running use the command jobs at the system prompt.


Return to Statistics Page