Help using Base SAS procedures

Proc Shewhart: Label out of control points with only one control limit

Reply
Contributor
Posts: 45

Proc Shewhart: Label out of control points with only one control limit

Version:  SAS 9.2 TS2M0


I have been working with proc shewhart to create control charts in ODS.  What I have done is add a label statement to label points on a shewhart control chart that are out of control by their count number (outlabel= option).  This works perfect when I am using both control limits, but when I do this with one control limit, it does not work.  I am looking for anyway to fix this, or a different way to do this.  I have also tried to just use the testlabel1= option, but that did not work as well.

Code for proc shewhart section:

/* Individuals Chart */

proc shewhart history=data2;

irchart &test*lot_count='*' / outlabel=(lot_count) testlabel1=' ' testlabel2=' '  nochart2 vref=vref ciindices lsl=&lsl usl=&usl readphases=all phaselegend vreflabpos=2 nolcl zerostd clipfactor=2 tests=1 to 4 totpanels=1;

inset stddev cpklcl='Cpk 95% Lower' cpk='Cpk' cpkucl='Cpk 95% Upper';

label &var="&var (&units)";

run;

Sample Data:

Count     AV

152.40
163.50
173.10
187.00
192.90
202.70
212.30
223.50
232.00
241.90
253.00
261.30
273.00
281.10
291.30
301.30
313.30
322.70
332.30
349.50
352.30
367.30
376.80
383.80
391.70
405.20
413.20
422.00
433.40
442.80
454.40
466.10
471.40
483.50
498.90
5012.40
514.90
527.70
530.90
542.20
551.40
565.00
574.40
583.50
593.10
602.30
612.50
622.10
632.30

With an upper specification limit of 15.

As just by looking at the data, they are within specification, but 2 points are outside of the upper control limit.  The outlabel= or test1label= option is not labeling them for some reason, I guess because of the "noucl" option in proc shewhart.   So I need some other way to label them in the plot by count.

Thanks,

Jeff

Message was edited by: Jeff Ollis

Super User
Posts: 10,508

Re: Proc Shewhart: Label out of control points with only one control limit

You might want to make some example data available to replicate the issue as well as values of the macro variables referenced.

Ask a Question
Discussion stats
  • 1 reply
  • 190 views
  • 0 likes
  • 2 in conversation