Resources

Tabulating Results for Multiple Variables

/****************************************************************/
/*          S A S   S A M P L E   L I B R A R Y                 */
/*                                                              */
/*    NAME: CAPTAB1                                             */
/*   TITLE: Tabulating Results for Multiple Variables           */
/* 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 Process;
   input P1-P10;
   datalines;
 72  223  332  138  110  145   23  293  353  458
 97   54   61  196  275  171  117   72   81  141
 56  170  140  400  371   72   60   20  484  138
124    6  332  493  214   43  125   55  372   30
152  236  222   76  187  126  192  334  109  546
  5  260  194  277  176   96  109  184  240  261
161  253  153  300   37  156  282  293  451  299
128  121  254  297  363  132  209  257  429  295
116  152  331   27  442  103   80  393  383   94
 43  178  278  159   25  180  253  333   51  225
 34  128  182  415  524  112   13  186  145  131
142  236  234  255  211   80  281  135  179   11
108  215  335   66  254  196  190  363  226  379
 62  232  219  474   31  139   15   56  429  298
177  218  275  171  457  146  163   18  155  129
  0  235   83  239  398   99  226  389  498   18
147  199  324  258  504    2  218  295  422  287
 39  161  156  198  214   58  238   19  231  548
120   42  372  420  232  112  157   79  197  166
178   83  238  492  463   68   46  386   45   81
161  267  372  296  501   96   11  288  330   74
 14    2   52   81  169   63  194  161  173   54
 22  181   92  272  417   94  188  180  367  342
 55  248  214  422  133  193  144  318  271  479
 56   83  169   30  379    5  296  320  396  597
;

proc capability data=Process outtable=Table noprint;
   var P1-P10;
   specs lsl=5 10 65 35 35 5 25 25 60 15
         usl=175 275 300 450 550 200 275 425 500 525;
run;

proc print data=Table label noobs;
   var _VAR_ _MEAN_ _STD_ _LSL_ _USL_ _CPK_;
   label _VAR_='Process';
run;