Produce the horizontal bar chart. SUMVAR= calculates the mean of the variable HEART for all the observations in each midpoint group. TYPE= specifies the mean statistic for the summary variable, HEART. FREQLABEL= and MEANLABEL= specify new column labels for the frequency and mean statistics. ERRORBAR= draws the error bars as empty bars and CLM= specifies the confidence level. COUTLINE= outlines the bars in black. NOFRAME suppresses the axis area frame.
proc gchart data=reflib.fitness;
   hbar age / type=mean
              sumvar=heart
              freqlabel='Number in Group'
              meanlabel='Mean  Heart Rate'
              errorbar=bars
              clm=95
              midpoints=(20 30 40 50)
              raxis=axis1
              maxis=axis2
              noframe
              coutline=black;
run;
quit;