EWMACHART Statement: MACONTROL Procedure

Saving Control Limit Parameters

See MACEW1 in the SAS/QC Sample LibraryYou can save the control limit arameters for an EWMA chart in a SAS data set; this enables you to use these parameters with future data (see Reading Preestablished Control Limit Parameters) or modify the parameters with a DATA step program.

The following statements read measurements from the data set Clips1 (see Creating EWMA Charts from Raw Data) and save the control limit parameters in a data set named Cliplim:

title 'Control Limit Parameters';
proc macontrol data=Clips1;
   ewmachart Gap*Day / weight    = 0.3
                       outlimits = Cliplim
                       nochart;
run;

The OUTLIMITS= option names the data set containing the control limit parameters, and the NOCHART option suppresses the display of the chart. The data set Cliplim is listed in Figure 9.7.

Figure 9.7: The Data Set Cliplim Containing Control Limit Information

Control Limit Parameters

_VAR_ _SUBGRP_ _TYPE_ _LIMITN_ _ALPHA_ _SIGMAS_ _MEAN_ _STDDEV_ _WEIGHT_
Gap Day ESTIMATE 5 .002699796 3 14.95 0.21108 0.3


Note that the data set Cliplim does not contain the actual control limits but rather the parameters required to compute the limits.

The data set contains one observation with the parameters for process Gap. The variable _WEIGHT_ contains the weight parameter used to compute the EWMAs. The value of _MEAN_ is an estimate of the process mean, and the value of _STDDEV_ is an estimate of the process standard deviation $\sigma $. The value of _LIMITN_ is the nominal sample size associated with the control limits, and the value of _SIGMAS_ is the multiple of $\sigma $ associated with the control limits. The variables _VAR_ and _SUBGRP_ are bookkeeping variables that save the process and subgroup-variable. The variable _TYPE_ is a bookkeeping variable that indicates that the values of _MEAN_ and _STDDEV_ are estimates rather than standard values. For more information, see OUTLIMITS= Data Set.

You can create an output data set containing the control limits and summary statistics with the OUTTABLE= option, as illustrated by the following statements:

title 'Summary Statistics and Control Limits';
proc macontrol data=Clips1;
   ewmachart Gap*Day / weight   = 0.3
                       outtable = Cliptab
                       nochart;
run;

The data set Cliptab is listed in Figure 9.8.

Figure 9.8: The OUTTABLE= Data Set Cliptab

Summary Statistics and Control Limits

_VAR_ Day _SIGMAS_ _LIMITN_ _WEIGHT_ _SUBN_ _SUBX_ _SUBS_ _LCLE_ _EWMA_ _MEAN_ _UCLE_ _STDDEV_ _EXLIM_
Gap 1 3 5 0.3 5 14.904 0.18716 14.8650 14.9362 14.95 15.0350 0.21108  
Gap 2 3 5 0.3 5 15.014 0.09317 14.8463 14.9595 14.95 15.0537 0.21108  
Gap 3 3 5 0.3 5 14.866 0.25006 14.8383 14.9315 14.95 15.0617 0.21108  
Gap 4 3 5 0.3 5 15.048 0.23732 14.8345 14.9664 14.95 15.0655 0.21108  
Gap 5 3 5 0.3 5 15.024 0.26792 14.8327 14.9837 14.95 15.0673 0.21108  
Gap 6 3 5 0.3 5 15.126 0.12260 14.8319 15.0264 14.95 15.0681 0.21108  
Gap 7 3 5 0.3 5 15.220 0.23098 14.8314 15.0845 14.95 15.0686 0.21108 UPPER
Gap 8 3 5 0.3 5 14.902 0.17254 14.8312 15.0297 14.95 15.0688 0.21108  
Gap 9 3 5 0.3 5 14.910 0.19824 14.8311 14.9938 14.95 15.0689 0.21108  
Gap 10 3 5 0.3 5 14.932 0.24035 14.8311 14.9753 14.95 15.0689 0.21108  
Gap 11 3 5 0.3 5 15.096 0.25618 14.8311 15.0115 14.95 15.0689 0.21108  
Gap 12 3 5 0.3 5 14.912 0.16903 14.8310 14.9816 14.95 15.0690 0.21108  
Gap 13 3 5 0.3 5 15.138 0.15928 14.8310 15.0285 14.95 15.0690 0.21108  
Gap 14 3 5 0.3 5 14.798 0.26329 14.8310 14.9594 14.95 15.0690 0.21108  
Gap 15 3 5 0.3 5 14.944 0.20876 14.8310 14.9548 14.95 15.0690 0.21108  
Gap 16 3 5 0.3 5 14.896 0.09965 14.8310 14.9371 14.95 15.0690 0.21108  
Gap 17 3 5 0.3 5 14.734 0.22512 14.8310 14.8762 14.95 15.0690 0.21108  
Gap 18 3 5 0.3 5 15.046 0.24141 14.8310 14.9271 14.95 15.0690 0.21108  
Gap 19 3 5 0.3 5 14.702 0.17880 14.8310 14.8596 14.95 15.0690 0.21108  
Gap 20 3 5 0.3 5 14.788 0.16634 14.8310 14.8381 14.95 15.0690 0.21108  


This data set contains one observation for each subgroup sample. The variable _EWMA_ contains the EWMAs. The variables _SUBX_, _SUBS_, and _SUBN_ contain the subgroup means, subgroup standard deviations, and subgroup sample sizes, respectively. The variables _LCLE_ and _UCLE_ contain the lower and upper control limits, and the variable _MEAN_ contains the central line. The variables _VAR_ and Day contain the process name and values of the subgroup-variable, respectively. For more information, see OUTTABLE= Data Set.

An OUTTABLE= data set can be read later as a TABLE= data set. For example, the following statements read Cliptab and display a EWMA chart (not shown here) identical to Figure 9.3:

title 'EWMA Chart for Gap Measurements';
proc macontrol table=Cliptab;
   ewmachart Gap*Day ;
run;

For more information, see TABLE= Data Set.