Sample 24911: Generate bubble labels
/* NOTE: POINTLABEL option valid starting with the SAS Version 8.0 release */
/* Reset global statements */
goptions reset=all;
/* Create sample data set ONE */
data one;
input x y z name $8.;
datalines;
.2 .3 3 Fred
.4 .7 4 Wilma
.6 .4 3 Barney
.8 .6 4 Betty
;
/* Specify AXIS1 statement assigned to horizontal X-axis */
axis1 offset=(5,5)pct order=(0 to 1 by .1);
/* Specify AXIS2 statement assigned to left vertical Y-axis */
axis2 offset=(5,5)pct order=(0 to 1 by .1);
/* Specify AXIS3 statement assigned to right vertical Y-axis */
axis3 offset=(5,5)pct order=(0 to 1 by .1);
/* Specify SYMBOL statement with POINTLABEL option */
symbol1 v=none i=none c=black pointlabel=(h=1.5 f=swissb "#name");
/* Specify TITLE statement */
title1 h=2.5 'Label Bubbles';
/* Generate BUBBLE plot */
proc gplot;
bubble y*x=z / haxis=axis1 vaxis=axis2 bsize=15;
plot2 y*x / vaxis=axis3 noaxis;
run;
quit;

Label bubble plots with a non-Z variable value using the PLOT2 statement and the POINTLABEL option on the SYMBOL statement.
| Type: | Sample |
| Topic: | SAS Reference ==> Procedures ==> GPLOT Query and Reporting ==> Creating Reports ==> Graphical ==> Graph Types ==> Plots ==> Bubble
|
| Date Modified: | 2005-08-31 03:03:12 |
| Date Created: | 2004-11-11 11:07:59 |
Operating System and Release Information
| SAS System | SAS/GRAPH | All | 8 TS M0 | n/a |