**Introduction to Control Charts**

While employed as a scientist/engineer for a large manufacturing corporation, I pulled a stint as trainer for my company’s Total Quality program. This role occupied half of my time for three or four years. A large component of our Total Quality initiative was related to Statistical Process Control (SPC). And of all the volumes of course materials used in this training, the most useful was a small, 136-page book called Understanding Variation.

Understanding Variation: The Key to Managing Chaos

Donald J. Wheeler

What made the book so useful was its down-to-earth approach to SPC and its reliance on real business and manufacturing examples.

After discussing the randomness but orderliness of data, the book introduces time series charts. Basically, a record of performance is put on paper, in graphical form, so a quick glance can show whether things are on track. Once you have such a chart, you need a system that helps indicate how much variation is acceptable, and how much means the process is out of control.

Let’s take a look at some sample data. I’ve generated a couple of months of normally distributed process data, which looks like this:

The gray vertical lines separate adjacent weeks. Without any special training, one could look at this data, see that it varies, and say that “some days are better than others”. But we have no way to characterize the variation. Walter Shewhart first applied some simple but effective numerical techniques to this type of data, and he called the result “control charts”. While the techniques were relatively simple to apply, they were based on solid statistical methods.

The first step is to add a line to the chart above representing the mean of the data:

We still can’t say anything more insightful than the data is distributed about the mean. In order to judge the variability in the data, we need first to quantify the variability. This can be done by analyzing a moving range chart, which is an effective measure of variation in the data, and simpler to compute than the standard deviation (at least in the days prior to desktop computers). Essentially, for a given day, we plot the absolute difference between that day’s value and the previous day’s value.

We can add a line for the mean as we did with the chart of raw values:

We still don’t know how much variability is “acceptable”, that is, attributable to common variation in the process. This is where some calculations are required. When using the moving range to determine “typical” variation, the maximum acceptable value of the moving range is 3.27 times the mean of the moving range. For this data, the mean of the moving range is 3.2, so the maximum acceptable moving range, or the Upper Control Limit for Ranges, is 10.5.

The variability in moving range is well under the Upper Control Limit (UCL). We can use the moving range to compute the control limits on the individual values data: the mean of the moving range is multiplied by 2.66, then added to and subtracted from the process data mean (this is roughly equivalent to using 3 times the standard deviation of the individual values data). Our Upper and Lower Control Limits (UCL and LCL) are thus 28.1 and 11.1.

In conjunction, these two graphs comprise an XMR chart, because it analyzes the X (individual values) and MR (moving range) data.

A quick glance at these charts shows that the process data falls well within the upper and lower control limits, that is, it is operating within the bounds of random variation, and we can say that the process is “In Control”. In truth, there are additional tests for randomness, because any patterns in the data even within the control limits means the process may be “Out of Control”. A detailed treatment of these additional tests is beyond the scope of this introduction.

In addition to the XMR methodology, there are several other types of control charts, which are used for different types of data and data collection. I plan to describe them in a future post.

**Further Reading**

ISO 9001 – Introduction to SPC

Selecting the Right Control Chart

**Commercial Statistical Process Control Software**

If you have a need for extensive Statistical Process Control capabilities, then you are not likely to want to build an entire solution yourself. There are a number of commercial packages that provide SPC functionality for Excel. There is one in particular which I will mention here: SPC for Excel. Written and supported by a client of mine, Business Process Improvement, or BPI Consulting, SPC for Excel is a turnkey SPC system in the form of an Excel add-in. SPC for Excel is compatible with Excel versions 2000 through 2007; this reduced view of its Excel 2007 ribbon tab shows the capabilities of SPC for Excel.

Jon Peltier says

Hi Damir –

The preferred approach is to calculate the mean and variation parameters (e.g., SD) at a point where the process has stabilized, that is, the process is in control. You then plot these values as the horizontal lines in the control chart, and don’t change them until the process is knowingly changed.

The dynamic control chart that this article links to calculates these parameters on all values in the chart, so if more observations are added, the parameters are recalculated. This is incorrect, as I designed that chart before I had been deeply involved in SPC-related activities.

Damir says

How do you calculate sigma when creating a control chart with UCL, LCL and sigma zones (+/- 1 to 3)?

Is the sigma “locked”–meaning calculated on a batch of parts sometimes in past leading to constant LCL and UCL? Or, is it dynamically calculated which leads to LCL and UCL changing over time?

If dynamically, how did (would) you deal with a process with SLOWLY increasing sigma (something getting loose on a machine)?

darman says

does this Run CC build from runs test (non-par analysis)?

Marilyn Sumonod says

can i ask some situation problem in how to make a control chart

please give me an example inside the organization..

thmxxxx………

Jon Peltier says

Marilyn – What are you looking for?

International Shipping says

We are a shipping company and we would like to know how XmR chart would be useful improve our delivery of shipments.

I got lost in the calculation of UCL & LCL metioned in post i.e “the mean of the moving range is multiplied by 2.66, then added to and subtracted from the process data mean (this is roughly equivalent to using 3 times the standard deviation of the individual values data). Our Upper and Lower Control Limits (UCL and LCL) are thus 28.1 and 11.1.”

Jon Peltier says

Using Shewhart’s formulas (XmR):

UCL = Process Mean + 2.66 * (Mean of Process Moving Range)

LCL = Process Mean – 2.66 * (Mean of Process Moving Range)

UCL = 19.6 + 2.66 * 3.2 = 28.1

LCL = 19.6 – 2.66 * 3.2 = 11.1

Using Mean and Standard Deviation:

UCL = Process Mean + 3 * (Process Standard Deviation)

LCL = Process Mean – 3 * (Process Standard Deviation)

UCL = 19.6 + 3 * 2.61 = 27.4

LCL = 19.6 – 3 * 2.61 = 11.8

The results are similar, in this case the XmR has a broader “acceptable” range. The XmR was easier to calculate when people didn’t have PCs on their desks.

Strictly speaking, the limits shouldn’t be calculated based on the data being observed. The limits should be computed when the process is deemed stable, then future observations compared to these limits.

DaleW says

Jon,

I fear that your advice has drifted from what Donald J. Wheeler recommends.

If you search for his excellent 2010 article “Individual Charts Done Right and Wrong” (QualityDigest.com), he advises that calculating control limits by “Limits for X = average ± 3 * global standard deviation statistic” is, well, “wrong” and “simply nothing more than another way to lie with statistics.”

With or without a PC, that XmR method “should always be the default option for computing limits for individual values.”

SPC relies on robust estimators to separate any signal from the noise, while =stdev(data) all too efficiently jumbles them together. Granted, if we KNEW that the process was free of special causes (signals), then =stdev(data) would be the best estimator of process common cause sigma, but the whole point of using SPC is to determine whether the process has detectable special causes . . .

-Dale

Genet says

I got lost in the calculation of UCL & LCL “the mean of the moving range is multiplied by 2.66, then added to and subtracted from the process data mean (the result is different when using 3 times the standard deviation of the individual values data). Our Upper and Lower Control Limits (UCL and LCL) are thus

mean392 R-BAR 80

UCL 501 UCLR 124

CL 392 CLR 80

LCL 284 LCLR 37

Jon Peltier says

Genet –

If X-bar = 392 and R-bar = 80:

UCL-R = R-bar * 3.27 = 262

LCL-R = 0 (by definition)

UCL-X = X-bar + 2.66 * R-bar = 392 + 2.66 * 80 = 605

LCL-X = X-bar – 2.66 * R-bar = 392 – 2.66 * 80 = 179

Aarti Kadyan says

In control charts which line is adjusted if necessary among cl ucl and lcl

Jon Peltier says

Aarti –

If the process is reevaluated, of course, all values are subject to change.

DaleW says

Aarti: For some processes with flexible targets, it may be reasonable to adjust the centerline (moderately) while keeping the distance from cl to each control limit the same. That’s how some short run SPC works.