/* View the first 5 observations of the STEP1 data */ PROC PRINT DATA=BIO.PULSE_STEP1 (OBS=5); RUN; /* Show information about STEP1 data - Review variable names */ PROC CONTENTS DATA=BIO.PULSE_STEP1 VARNUM; RUN; /* Note the raw data for our categorical variables are coded as numbers */ /* We have not yet created translations for the variables in the STEP1 Data */ /* We will cover how to handle that scenario in the translation tutorials */ /* This will not be an issue here as we focus on only Quantitative variables */ /* Default output for PROC SGPLOT with HISTOGRAM statement */ PROC SGPLOT DATA=BIO.PULSE_STEP1; HISTOGRAM HEIGHT; RUN; /* Adding Density Curves to histograms with the DENSITY statement */ PROC SGPLOT DATA=BIO.PULSE_STEP1; /* We still start with a HISTOGRAM statement */ HISTOGRAM HEIGHT; /* Now we add "Best" Normal distribution for this data */ DENSITY HEIGHT / TYPE = NORMAL; /* Now we add "Best" Guess at the TRUE distribution for this data */ DENSITY HEIGHT / TYPE = KERNEL; RUN; /* Repeat for the rest of our quantitative variables */ /* Each requires a new PROC SGPLOT */ PROC SGPLOT DATA=BIO.PULSE_STEP1; HISTOGRAM WEIGHT; DENSITY WEIGHT / TYPE = NORMAL; DENSITY WEIGHT / TYPE = KERNEL; RUN; PROC SGPLOT DATA=BIO.PULSE_STEP1; HISTOGRAM AGE; DENSITY AGE / TYPE = NORMAL; DENSITY AGE / TYPE = KERNEL; RUN; PROC SGPLOT DATA=BIO.PULSE_STEP1; HISTOGRAM PULSE1; DENSITY PULSE1 / TYPE = NORMAL; DENSITY PULSE1 / TYPE = KERNEL; RUN; PROC SGPLOT DATA=BIO.PULSE_STEP1; HISTOGRAM PULSE2; DENSITY PULSE2 / TYPE = NORMAL; DENSITY PULSE2 / TYPE = KERNEL; RUN; /* Default output for PROC SGPLOT with VBOX statement */ PROC SGPLOT DATA=BIO.PULSE_STEP1; VBOX HEIGHT; RUN; /* Default output for PROC SGPLOT with HBOX statement */ PROC SGPLOT DATA=BIO.PULSE_STEP1; HBOX HEIGHT; RUN; /* I am sure there are numerous interesting options for the VBOX and HBOX statements but I don't usually modify these plots */ /* Repeat for the remaining variables using VBOX (my preference) */ PROC SGPLOT DATA=BIO.PULSE_STEP1; VBOX WEIGHT; RUN; PROC SGPLOT DATA=BIO.PULSE_STEP1; VBOX AGE; RUN; PROC SGPLOT DATA=BIO.PULSE_STEP1; VBOX PULSE1; RUN; PROC SGPLOT DATA=BIO.PULSE_STEP1; VBOX PULSE2; RUN;