Note: See Saving Decision Limits Using ANOM BOXCHART in the SAS/QC Sample Library.
You can save the decision limits for an ANOM chart, together with the parameters used to compute the limits, in a SAS data set.
The following statements read measurements from the data set LabelDeviations
(see Creating ANOM Boxcharts from Response Values.) and save the decision limits displayed in Figure 4.3 in a data set named LabelLimits
:
proc anom data=LabelDeviations; boxchart Deviation*Position / outlimits=LabelLimits nochart; run;
The OUTLIMITS= option names the data set containing the decision limits, and the NOCHART option suppresses the display of the chart. The data set LabelLimits is listed in Figure 4.7.
Figure 4.7: The Data Set LabelLimits Containing Decision Limit Information
The data set LabelLimits
contains one observation with the limits for response Deviation
. The values of _LDLX_
and _UDLX_
are the lower and upper decision limits for the means, and the value of _MEAN_
is the weighted average of the group means, which is represented by the central line.
The values of _MEAN_
, _MSE_
, _DFE_
, _LIMITK_
, _LIMITN_
, and _ALPHA_
are the parameters used to compute the decision limits. The value of _MSE_
is the mean square error, and the value of _DFE_
is the associated degrees of freedom. The value of _LIMITK_
is the group size (k), the value of _LIMITN_
is the nominal sample size associated with the decision limits, and the value of _ALPHA_
is the value of the significance level (). The variables _VAR_
and _GROUP_
are bookkeeping variables that save the response and group-variable. The variable _TYPE_
is a bookkeeping variable that indicates whether the values of _MEAN_
and _MSE_
are estimates computed from the data or standard (known) values specified with procedure options. In most applications, the
value of _TYPE_
will be 'ESTIMATE.'
Note: See Saving Decision Limits and Summary Statistics in the SAS/QC Sample Library.
You can create an output data set containing both decision limits and group summary statistics with the OUTTABLE= option, as illustrated by the following statements:
proc anom data=LabelDeviations; boxchart Deviation*Position / outtable=LabelTab nochart; run;
The data set LabelTab
is listed in Figure 4.8.
Figure 4.8: The Data Set LabelTab
Summary Statistics and Decision Limits |
_VAR_ | Position | _ALPHA_ | _LIMITN_ | _SUBN_ | _LDLX_ | _SUBX_ | _MEAN_ | _UDLX_ | _EXLIM_ | _SUBMIN_ | _SUBQ1_ | _SUBMED_ | _SUBQ3_ | _SUBMAX_ |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Deviation | 1 | 0.05 | 10 | 10 | -.009878975 | -0.022342 | .009991333 | 0.029862 | LOWER | -0.06466 | -0.03623 | -0.026195 | -0.00163 | 0.00944 |
Deviation | 2 | 0.05 | 10 | 10 | -.009878975 | 0.016241 | .009991333 | 0.029862 | -0.03323 | -0.02014 | 0.020420 | 0.04378 | 0.05641 | |
Deviation | 3 | 0.05 | 10 | 10 | -.009878975 | 0.006011 | .009991333 | 0.029862 | -0.04404 | -0.01394 | 0.005680 | 0.02849 | 0.04855 | |
Deviation | 4 | 0.05 | 10 | 10 | -.009878975 | 0.064729 | .009991333 | 0.029862 | UPPER | 0.03620 | 0.05298 | 0.060315 | 0.07551 | 0.10729 |
Deviation | 5 | 0.05 | 10 | 10 | -.009878975 | 0.008121 | .009991333 | 0.029862 | -0.04640 | -0.00741 | 0.007625 | 0.03021 | 0.03736 | |
Deviation | 6 | 0.05 | 10 | 10 | -.009878975 | -0.012812 | .009991333 | 0.029862 | LOWER | -0.03839 | -0.02845 | -0.009495 | 0.00167 | 0.00710 |
This data set contains one observation for each group sample. The variable _SUBMIN_
contains the group minimums, and the variable _SUBQ1_
contains the first quartile for each group. The variables _SUBX_
and _SUBMED_
contain the group means and medians. The variable _SUBQ3_
contains the third quartiles, _SUBMAX_
contains the group maximums, and _SUBN_
contains the group sample sizes. The variables _LDLX_
and _UDLX_
contain the lower and upper decision limits, and the variable _MEAN_
contains the central line. The variables _VAR_
and Position
contain the response name and values of the group-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 LabelTab
and display an ANOM boxchart (not shown here) identical to the chart in Figure 4.3:
title 'Analysis of Label Deviations'; proc anom table=LabelTab; boxchart Deviation*Position / odstitle=title; label _SUBX_ = 'Mean Deviation from Center (mm)'; run;
Because the ANOM procedure simply displays the information in a TABLE= data set, you can use TABLE= data sets to create specialized ANOM boxcharts.
For more information, see TABLE= Data Set.