|
|
|
||||
|
|
|||||
This is a very brief introduction to show you the basics of using the SAS Display Manager for running your programs. This introduction shows just the essentials that you need to know for using SAS Display Manager. There are so many options that it would be too confusing to even begin to explore them. Let's start by opening SAS.
Let's start by typing this short little program into the Program Editor window as shown below.
Below you see this program typed into the Program Editor.data test; input id x y; cards; 1 3 8 2 6 2 3 7 4 4 4 3 5 9 3 ; run; proc print data=test; run;
Running the program caused things to show up in the Log Window and the Output Window as shown below. The log window shows your program along with messages (NOTEs) about the running of your program about your program. In the Output Window you see the output of SAS procedures (in this case, the output of the proc print).
Let's have a better look at the Log Window.
We can double click the Title Bar (indicated by the arrow below)
to zoom the window and make it bigger.
Now we can see the Log Window better. The log tells us that work.test has five observations and three variables (that is right) and it tells us that the proc print took 0.11 seconds.
Now that the excitement of the Log Window has
worn off, lets return the window back to its original size by clicking
the unzoom button, shown below.
Now that we are back to the three window configuration, let's type
these statements into the Program Window.
This is shown below.proc means data=test; run;
We click on the running bald woman to run the program, and
we see the program shown back to us in the Log Window and some new
output in the Output Window.
We double click the Title Bar for the Output Window
so we can zoom it and get a better look at our data. The zoomed window
is shown below.
Now that we have had a good look at the data, we will unzoom the output window. Say that we really just wanted the mean of x and y (and not id). Instead of retyping the entire program, we can click the Program Editor window, and then choose Locals then Recall Text (see below) and that will bring back the program we were working on previously so we can edit it and change it.
Now that the text has been recalled, we can just delete the id as shown below.
We click on the running person to run the revised program.
and the result is shown below. You can see in the Output Window that you have just the means of X and Y.
What happens when you make an error? Say that you typed
in this program that is clearly incorrect and ran it.
The result is shown below. In the Log Window you can see the error message in red, saying Variable Z not (the rest of the message is not found).proc means data=test; var x y z; run;
When this happens, you can click the Program Editor
Window, recall the program (see below), fix the error, and then run the
program again.
Running programs in SAS display manager can sometimes be like a repeating loop. You
- type in your in the Program Editor
- Run it (by clicking the running person)
- You look at the Log Window and Output Window find some problems or changes you want to make
- Go back to the Program Editor
- Recall your program (Locals then Recall Text from the pull-down).
- etc. etc. etc.
For more information, see The User Interface of SAS For Windows
UCLA Researchers are invited to our Statistical Consulting Services
We recommend others to our list of Other Resources for Statistical Computing Help
These pages are Copyrighted (c) by UCLA Academic Technology Services