Skip to Content
Producing High-Quality Figures Using SAS/GRAPH and ODS Graphics Procedures
book

Producing High-Quality Figures Using SAS/GRAPH and ODS Graphics Procedures

by Charlie Chunhua Liu
February 2015
Beginner to intermediate
282 pages
7h 27m
English
Chapman and Hall/CRC
Content preview from Producing High-Quality Figures Using SAS/GRAPH and ODS Graphics Procedures
71Scatter and Jittered Scatter Plots
** Produce the Line-up jittered scatter plot;
%macro LineUp_Jitter (idn =, xvar =, yvar =, lvl =, jitter =,
odn =);
** Get the Min and Max values and save them into macro
variables;
PROC MEANS DATA = &idn. MIN MAX maxdec = 2 noprint;
VAR &yvar.;
OUTPUT OUT = tmp_STAT min = min max = max;
RUN;
data _null_;
set tmp_stat;
call symput(‘Min’, min);
call symput(‘Max’, max);
run;
proc sort data = &idn. out = d_tmp;
by &yvar.;
run;
data add_tmp;
set d_tmp;
do i = floor(&min.) to ceil(&max.) by &lvl.;
if i < = &yvar. < i+1 then yvar_int = i;
end;
run;
** get the number of data points at each interval by x-axis
value;
proc freq data = add_tmp noprint;
tables &xvar.*yvar_int/out = freqdata;
run;
data jitter_sum;
retain ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Carpenter's Guide to Innovative SAS Techniques

Carpenter's Guide to Innovative SAS Techniques

Art Carpenter
What Employees Want Most in Uncertain Times

What Employees Want Most in Uncertain Times

Kristine W. Powers, Jessica B.B. Diaz

Publisher Resources

ISBN: 9781482207026