The SAS Display Manager provides a self contained interactive environment within which you can enter and execute SAS code. Pull down menus are available to facilitate accessing of data sets and execution of procedures; e.g., Interactive Data Analysis and Design of Experiments.
This chapter contains the following sections:
This environment is available in all windows style implementations of the SAS System at Virginia Tech. In the Macintosh and Microsoft Windows environments, you can start the SAS Display Manager by double clicking on the SAS icon.
If you are logging onto a UNIX system using an X server, you can use the capabilities of the X Windows System and your window manager to facilitate use of the SAS System. As typical of X applications, you must first grant permission for the UNIX system to display on your server and then define the DISPLAY environmental variable on the X client to specify the X server where SAS will direct its output displays. Then, to start the Display Manager, simply enter the command: sas
If you are using a Macintosh, Microsoft Windows, or an X server with UNIX, you can use the associated mouse to move the cursor on the screen and make selections from the available menus.
The Display Manager provides full screen editing capabilities and an interactive interface to facilitate the writing and execution of SAS programs. Once you have started the Display Manager, you can enter your code into the program editor and then enter (or select from the Local menu) the command submit to execute this code. If you are using a Windows display manager, you can use the mouse, menus and other features of the manager (e.g., copy, cut, and paste) to edit text within the Program Editor Window; otherwise you can enter commands on the command line or in the prefix area to perform these functions.
If you already saved the SAS program as a file, you can use the include command to copy the contents of the file into the Program editor window. Alternatively, you can use Assist (under the Globals menu) to create and execute procedures against SAS data sets without having to enter SAS code.
Several windows are supported by the Display Manager:
DMS commands are executed by typing them on the command line of the appropriate window and pressing the <Enter> key or by making selections from menus. Several of the most commonly used commands are assigned to function (F) keys so that they may be executed by a single key stroke. The KEYS command, issued from the command line of any window, may be used to view a listing of the commands currently assigned to each key for that window (The F Key definitions in the PC implementation differ significantly from those on the mainframe.). Enter the command END on the command line of the KEYS Window to return to the prior screen.
Use of interactive SAS provides the following advantages:
Here is a list of some commands commonly invoked from the Display Manager command line (see Initial SAS Exercises for instructions for displaying the command line if it is not already present):
To turn on or turn off insert mode, try using the Ins or Insert key on your keyboard. If this key fails to function as desired, try using the Ctrl-X (that is press the Ctrl or Control Key, and, while it is depressed, press the "x" key) key combination.
If you are using SAS the DOS version for PCs, you will observe a prefix area (===== or numbers) along the left margin of the Program Editor Window. This region of the screen is used for entering "prefix" commands to manipulate lines within the display.
If you are using a Windows based environment and no prefix area is displayed, you can enable this capability by entering the command: num on
Likewise you can turn off this feature by entering: num off
The Display Manager prefix area editing capabilities are similar to those found in some text editors, for example uni-Xedit on VTAIX or Kedit in MS/DOS; however, several of the functions have different names. For example, the Prefix Area Commands P (Preceding), F (Following), and A (Addlines) are replaced by the SAS Program Editor commands B (Before), A (After), and I (Insert). The PgUp and PgDn are used to move backward and forward in a file. Prefix area commands may be entered in upper, lower, or mixed case.
Some of the most commonly used prefix area commands include:
User Services
Virginia Tech Computing Center