Previous Page | Next Page

The GPLOT Procedure

Example 1: Generating a Simple Bubble Plot


Procedure features:

BUBBLE statement option:

HAXIS=

Other features:

GOPTIONS statement option:

BORDER

AXIS statement

FORMAT statement

Sample library member: GPLBUBL1

[Example Bubble Plot]

This example shows a bubble plot in which each bubble represents a category of engineer. The plot shows engineers on the horizontal axis and average salaries on the vertical axis. Each bubble's vertical location is determined by the average salary for the category. Each bubble's size is determined by the number of engineers in the category: the more engineers, the larger the bubble.

 Note about code
goptions reset=all border;
 Note about code
data jobs;
   length eng $5;
   input eng dollars num;
   datalines;
Civil 27308 73273
Aero  29844 70192
Elec  22920 89382
Mech  32816 19601
Chem  28116 25541
Petro 18444 34833
;
 Note about code
title1 "Member Profile"
title2 "Salaries and Number of Member Engineers";
footnote j=r "GPLBUBL1";
 Note about code
axis1 offset=(5,5);
 Note about code
proc gplot data=jobs;
   format dollars dollar9.;
   bubble dollars*eng=num / haxis=axis1;
run;
quit;

Previous Page | Next Page | Top of Page