Chapter Contents
Chapter Contents
Previous
Previous
Next
Next
RCHART Statement

Example 39.2: Specifying Control Limit Information

See SHWREX2 in the SAS/QC Sample Library

This example illustrates how you can use a DATA step program to create a LIMITS= data set. You can provide previously established values for the limits and central line with the variables _LCLR_, _R_, and _UCLR_, as in the following statements:

   data dlimits2;
      length _var_ _subgrp_ _type_ $8;
      _var_    = 'time';
      _subgrp_ = 'lot';
      _type_   = 'STANDARD';
      _limitn_ = 6;
      _lclr_   = .03;
      _r_      = .12;
      _uclr_   = .25;
   run;

The following statements* apply the control limits in DLIMITS2 to the measurements in DISKS2 (see "Reading Preestablished Control Limits" ) and create the R chart shown in Output 39.2.1:

   title 'Specifying Control Limit Information';
   symbol v=dot c=rose;
   proc shewhart data=disks2 limits=dlimits2;
      rchart time*lot / cframe   = vipb
                        cinfill  = ywh
                        cconnect = rose;
   run;

Output 39.2.1: Reading Control Limits from DLIMITS2
rex2a.gif (5468 bytes)

In some cases, a standard value (\sigma_{0}) may be available for the process standard deviation. The following DATA step creates a data set named DLIMITS3 that provides this value:

   data dlimits3;
      length _var_ _subgrp_ _type_ $8;
      _var_    = 'time';
      _subgrp_ = 'lot';
      _stddev_ = .045;
      _limitn_ = 6;
      _type_   = 'STDSIGMA';
   run;

The variable _TYPE_ is a bookkeeping variable whose value indicates that the value of _STDDEV_ is a standard value rather than an estimate.

The following statements read the value of \sigma_{0} from DLIMITS3 and create the R chart shown in Output 39.2.2:

   title 'Specifying Control Limit Information';
   symbol v=dot c=rose;
   proc shewhart data=disks2 limits=dlimits3;
      rchart time*lot / nolimit0
                        cframe   = vipb
                        cinfill  = ywh
                        cconnect = rose;
   run;

The NOLIMIT0 option suppresses the display of a fixed lower control limit if the value of the limit is zero (which is the case in this example).

Output 39.2.2: Reading in Standard Value for Process Standard Deviation
rex2b.gif (5353 bytes)

Instead of specifying \sigma_{0}with the variable _STDDEV_ in a LIMITS= data set, you can use the SIGMA0= option in the RCHART statement. The following statements create an R chart identical to the chart shown in Output 39.2.2:

   proc shewhart data=disks;
      rchart time*lot / sigma0=.045 nolimit0;
   run;

For more information, see "LIMITS= Data Set" .

Chapter Contents
Chapter Contents
Previous
Previous
Next
Next
Top
Top

Copyright © 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.