Chapter Contents Previous Next
 XSCHART Statement

## Example 44.3: Analyzing Nonnormal Process Data

 See SHWXS4 in the SAS/QC Sample Library

The standard control limits for s charts (see Table 44.22) are calculated under the assumption that the data are normally distributed. This example illustrates how a tranformation to normality can be used in conjunction with and s charts.

The length of a metal brace is measured in centimeters for each of 20 braces sampled daily. Subgroup samples are collected for nineteen days, and the data are analyzed to determine if the manufacturing process is in statistical control.

   data lengdata;
informat day date7.;
format day date5.;
label length='Brace Length (cm)';
input day @;
do i=1 to 5;
input length @;
output;
end;
drop i;
datalines;
02JAN86  113.64  119.60  111.66  111.88  125.29
02JAN86  114.08  115.28  127.84  109.97  109.34
02JAN86  109.65  121.76  112.17  116.01  111.64
02JAN86  112.70  114.43  110.27  114.76  125.89
03JAN86  115.92  113.62  117.52  114.44  118.08
03JAN86  111.13  118.42  112.16  112.25  107.71
03JAN86  110.46  113.78  109.89  114.59  116.98
03JAN86  111.06  113.76  115.53  110.88  115.47
.         .       .       .       .       .
.         .       .       .       .       .
.         .       .       .       .       .
20JAN86  112.84  109.01  110.03  114.44  115.21
20JAN86  115.15  112.34  114.99  109.70  111.20
20JAN86  117.81  119.51  109.03  111.61  118.01
20JAN86  113.55  114.78  112.91  111.87  118.54
;


The following statements create preliminary and s charts for the lengths:

   title 'Mean and Standard Deviation Charts for Brace Length';
symbol v=dot c=salmon;
proc shewhart data=lengdata;
xschart length*day / cframe   = lib
cinfill  = bwh
cconnect = salmon;
run;


The charts are shown in Output 44.3.1.

Output 44.3.1: and s Charts

The s chart suggests that the process is not in control, since the standard deviation of the measurements recorded on January 9 exceeds its upper control limit. In addition, a number of other points on the s chart are close to the control limits.

The following statements create a box chart for the lengths (for more information on box charts, see Chapter 32, "BOXCHART Statement").

   title 'Box Chart for Brace Length';
proc shewhart data=lengdata;
boxchart length*day / serifs
nolegend
nohlabel
cinfill  = bwh
cboxfill = ywh
cboxes   = black
cframe   = lib;
run;

The chart, shown in Output 44.3.2, reveals that most of the subgroup distributions are skewed to the right. Consequently, the s chart shown in Output 44.3.1 should be interpreted with caution, since control limits for s charts are based on the assumption that the data are normally distributed.

No special cause for the skewness of the subgroup distributions is discovered. This indicates that the process is in statistical control and that the length distribution is naturally skewed.

Output 44.3.2: Box Chart

The following statements apply a lognormal transformation to the length measurements and display a box chart for the transformed data:

   data lengdata;
set lengdata;
logleng=log(length-105);
label logleng='log(Length-105)';
run;

   title 'Box Chart for log(Length-105)';
proc shewhart data=lengdata;
boxchart logleng*day / serifs
nohlabel
nolegend
cinfill  = bwh
cboxfill = ywh
cboxes   = black
cframe   = lib;
run;


The chart, shown in Output 44.3.3, indicates that the subgroup distributions of LOGLENG are approximately normal (this can be verified with goodness-of-fit tests by using the CAPABILITY procedure).

Finally, and s charts, shown in Output 44.3.4, are created for LOGLENG. They indicate that the variability and mean level of the transformed lengths are in control.

   title 'Mean and Standard Deviation Charts for log(Length)';
proc shewhart data=lengdata;
xschart logleng*day / split    = '/'
cframe   = lib
cinfill  = bwh
cconnect = salmon;
label logleng='Avg log of Length/Std Dev';
run;


Output 44.3.3: Box Chart for Transformed Data

Output 44.3.4: and s Charts for Transformed Length

 Chapter Contents Previous Next Top