O'Reilly logo

SAS Essentials: Mastering SAS for Data Analytics, 2nd Edition by Wayne A. Woodward, Alan C. Elliott

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

18CREATING CUSTOM GRAPHS

SAS provides several procedures for creating graphs, which are an essential part of data analysis. In this chapter, graphs that are often used to complement the data analyses discussed in this book are illustrated by example. Some of these were discussed in earlier chapters. This chapter provides more details and introduces graphs that have not been discussed earlier.

In fact, SAS provides a number of other sophisticated techniques for creating a variety of graphs that are not discussed in this chapter. However, you should be able to take what you learn here and adapt it to other SAS graphs.

18.1 CREATING SCATTERPLOTS AND LINE GRAPHS USING GPLOT

PROC GPLOT is the basic routine used to obtain several types of graphs in SAS. This section illustrates how to create scatterplots and line graphs using PROC GPLOT, with an emphasis on creating graphs that are useful for data analysis. The abbreviated syntax for this procedure is as follows:

PROC GPLOT <options>; <PLOT plot‐request(s)/ option(s)>;

It is a good idea to include the following command to reset all SAS graphics options before you use PROC GPLOT or other SAS graph procedures:

GOPTIONS RESET=ALL;

Moreover, it is a ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required