Chapter Contents |
Previous |
Next |
Specialized Control Charts |
There is considerable disagreement on how to handle autocorrelation in process data. Consider the following three views:
An example of the last approach is presented in the remainder of this section simply to demonstrate the use of the ARIMA procedure in conjunction with the SHEWHART procedure. The ARIMA procedure models the autocorrelation and saves the residuals in an output data set; the SHEWHART procedure creates a control chart using the residuals as input data.
In the chemical data example, the residuals can be computed as forecast errors and saved in an output SAS data set with the FORECAST statement in the ARIMA procedure.
proc arima data=chemical; identify var=xt; estimate p=1 method=ml; forecast out=results id=t; run;The output data set (named RESULTS) saves the one-step-ahead forecasts as a variable named FORECAST, and it also contains the original variables XT and T. You can create a Shewhart chart for the residuals by using the data set RESULTS as input to the SHEWHART procedure.
symbol v=dot c=yellow; title 'Residual Analysis Using AR(1) Model'; proc shewhart data=results(firstobs=4 obs=100) graphics; xchart xt*t / npanelpos = 100 split = '/' trendvar = forecast xsymbol = xbar ypct1 = 40 vref2 = 70 to 100 by 10 lvref = 2 nolegend cframe = vigb cconnect = yellow cinfill = vlib; label xt = 'Residual/Forecast' t = 'Time'; run;The chart is shown in Figure 49.4. Specifying TRENDVAR=FORECAST plots the values of FORECAST in the lower chart and plots the residuals (XT - FORECAST) together with their limits in the upper chart.*
Various other methods can be applied with this data. For example, Montgomery and Mastrangelo (1991) suggest fitting an exponentially weighted moving average (EWMA) model and using this model as the basis for a display that they refer to as an EWMA central line control chart.
Before presenting the statements for creating this display, it is helpful to review some terminology. The EWMA statistic plotted on a conventional EWMA control chart is defined as
The EWMA chart (which you can construct with the MACONTROL procedure) is based on the assumption that the observations xt are independent. However, in the context of autocorrelated process data (and more generally in time series analysis), the EWMA statistic zt plays a different role:* it is the optimal one-step-ahead forecast for a process that can be modeled by an ARIMA(0,1,1) model
provided that the weight parameter is chosen as . This statistic is also a good predictor when the process can be described by a subset of ARIMA models for which the process is "positively autocorrelated and the process mean does not drift too quickly."*
You can fit an ARIMA(0,1,1) model to the chemical data with the following statements. A summary of the fitted model is shown in Figure 49.5.
proc arima data=chemical; identify var=xt(1); estimate q=1 method=ml noint; forecast out=ewma id=t; run;
The forecast values and their standard errors (variables FORECAST and STD), together with the original measurements, are saved in a data set named EWMA. The EWMA central line control chart plots the forecasts from the ARIMA(0,1,1) model as the central "line," and it uses the standard errors of prediction to determine upper and lower control limits. You can construct this chart, shown in Figure 49.6,* with the following statements:
data ewma; set ewma(firstobs=2 obs=100); run; data ewmatab; length _var_ $ 8 ; set ewma (rename=(forecast=_mean_ xt=_subx_)); _var_ = 'xt'; _sigmas_ = 3; _limitn_ = 1; _lclx_ = _mean_ - 3 * std; _uclx_ = _mean_ + 3 * std; _subn_ = 1;
symbol v=dot c=yellow; title 'EWMA Center Line Control Chart'; proc shewhart table=ewmatab graphics; xchart xt*t / npanelpos = 100 xsymbol = 'Center' cinfill = vlib cframe = vigb cconnect = yellow llimits = 1 nolegend; label _subx_ = 'Observed' t = 'Time' ; run;Note that EWMA is read by the SHEWHART procedure as a TABLE= input data set, which has a special structure intended for applications in which both the statistics to be plotted and their control limits are pre-computed. The variables in a TABLE= data set have reserved names beginning and ending with the underscore character; for this reason, FORECAST and XT are temporarily renamed as _MEAN_ and _SUBX_, respectively. For more information on TABLE= data sets, see "Input Data Sets" in the chapter for the chart statement in which you are interested.
Again, the conclusion is that the process is in control. While Figure 49.4 and Figure 49.6 are not the only displays that can be considered for analyzing the chemical data, their construction illustrates the conjunctive use of the ARIMA and SHEWHART procedures in process control applications involving autocorrelated data.
Chapter Contents |
Previous |
Next |
Top |
Copyright © 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.