Displaying a Confidence Interval for Cpm

/****************************************************************/
/*          S A S   S A M P L E   L I B R A R Y                 */
/*                                                              */
/*    NAME: CAPSPEC3                                            */
/*   TITLE: Displaying a Confidence Interval for Cpm            */
/* PRODUCT: QC                                                  */
/*  SYSTEM: ALL                                                 */
/*    KEYS: Capability Analysis,                                */
/*   PROCS: CAPABILITY                                          */
/*    DATA:                                                     */
/*                                                              */
/* SUPPORT: saswgr                                              */
/*     REF: SAS/QC Software:  Usage and Reference, Version 6,   */
/*          First Edition, Volume 1 and Volume 2                */
/*    MISC:                                                     */
/*                                                              */
/*  Examples in the documentation were created using the        */
/*    statement:  ods listing style=statistical;                */
/*                                                              */
/****************************************************************/

data Amps;
   label Decibels = 'Amplification in Decibels (dB)';
   input Decibels @@;
   datalines;
4.54 4.87 4.66 4.90 4.68 5.22 4.43 5.14 3.07 4.22
5.09 3.41 5.75 5.16 3.96 5.37 5.70 4.11 4.83 4.51
4.57 4.16 5.73 3.64 5.48 4.95 4.57 4.46 4.75 5.38
5.19 4.35 4.98 4.87 3.53 4.46 4.57 4.69 5.27 4.67
5.03 4.50 5.35 4.55 4.05 6.63 5.32 5.24 5.73 5.08
5.07 5.42 5.05 5.70 4.79 4.34 5.06 4.64 4.82 3.24
4.79 4.46 3.84 5.05 5.46 4.64 6.13 4.31 4.81 4.98
4.95 5.57 4.11 4.15 5.95
;

title 'Boosting Power of Telephone Amplifiers';
proc capability data=Amps noprint alpha=0.10;
   var Decibels;
   spec  target = 5  lsl = 4  usl = 6
        ltarget = 2 llsl = 3 lusl = 4;
   histogram Decibels / odstitle = title;;
   inset cpklcl cpk cpkucl / header = '90% Confidence Interval'
                             format = 6.3;
run;

ods select indices;
proc capability data=Amps alpha=0.10;
   spec  target = 5  lsl = 4  usl = 6
        ltarget = 2 llsl = 3 lusl = 4;
   var Decibels;
run;