Quick 3D Graph in PC SAS
An example of creating a 3D vertical bar chart that is suitable for publication
Here are the steps used to create this graph:

Run a PROC G3D
Tinker with the display in the Results Viewer
Now comes the fun part. You can change the display in any number of ways interactively.

| Var1 | Var2 |
Var3 |
|---|---|---|
| 1 | 2 | 1063315.2642 |
| 2 | 1 | 34614651.345 |
| 3 | 1 | 2650246.4126 |
| 4 | 3 | 26121344.23 |
| 5 | 4 | 1235123.12 |
| etc... |
Set your output preferences from the menu bar as follows:
- Tools-->Options-->Preferences
- Select the "Results" tab and make the following selections to direct output to HTML.

Run a PROC G3D
* Note: activex device only works with PC/Sas;Look at the bottom of youir screen and open the "Results Viewer". You will see something like this:
goptions device=activex;
* Express the plot as y*x=z;
proc g3d data=sasuser.mydata;
scatter var2 * var1 = var3 /grid ;
format var3 8.0;
run;
quit;
Tinker with the display in the Results Viewer
Now comes the fun part. You can change the display in any number of ways interactively. - Put the cursor on the graph and right-mouse to pull up a list of options Select Chart Type--> Vertical Bar
- To make the Z axis run from 5 to 1, right-mouse over the graph again and select Graph Preferences, select Axis tab, select Depth from the drop-down and check Reverse. You can play with colors, title, and other attributes with other tabs in the Graph Preferences window as well.
- Double-click on the var1, var2 or var3 axis labels to create more descriptive labels for each axis.
- Right-mouse and select Titles-->Title or Footnote to complete the graph
- Right-mouse and select Save as... to save the final graph as a jpg or Copy it into a Word document or send directly to a printer.

