Chapter Contents |
Previous |
Next |
XCHART Statement |
See SHWOC1 in the SAS/QC Sample Library |
This example
uses the GPLOT procedure and the DATA
step function PROBNORM to plot operating characteristic (OC)
curves for charts
with 3 limits. An OC curve is plotted for each of the
subgroup samples sizes 1, 2, 3, 4, and 16.
Refer to page 226 in Montgomery (1996).
Each curve plots the probability of not detecting a shift
of magnitude in the process mean as a function of .The value of is computed using the following formula:
The following statements compute (the variable
BETA) as a function of (the variable NU). The
variable NSAMPLE contains the sample size.
data oc; keep beta nsample nu; do nsample=1, 2, 3, 4, 16; do j=0 to 400; nu=j/100; beta=probnorm( 3-nu*sqrt(nsample)) - probnorm(-3-nu*sqrt(nsample)); output; end; end; label nu ='Shift in Population Mean (Unit=Std Dev)' beta='Probability of Not Detecting Shift'; run;
The following statements use the GPLOT procedure to display
the OC curves shown in Output 42.3.1:
symbol1 v=none i=join w=2 c=red; symbol2 v=none i=join w=2 c=green; symbol3 v=none i=join w=2 c=yellow; symbol4 v=none i=join w=2 c=blue; symbol5 v=none i=join w=2 c=white; title1 'OC Curves for Shewhart Charts for Means'; proc gplot data=oc; plot prob*t=nsample / frame legend=legend1 vaxis=axis1 haxis=axis2 autovref autohref lvref = 2 lHREF=2 vzero hzero cframe = ligr cvref = white; axis1 label =(r=0 a=90) value =(t=1 ' ') order =(0.0 0.2 0.4 0.6 0.8 1.0) minor =none offset=(0,0); axis2 order =(0 1 2 3 4) offset=(0,0) minor =(n=3); legend1 label=('Sample Size n:'); run;Output 42.3.1: OC Curves for Different Subgroup Sample Sizes
Chapter Contents |
Previous |
Next |
Top |
Copyright © 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.