# The 8 steps to creating a $\bar{X}$ and R control chart

Once you decide to monitor a process and after you determine using an $\bar{X}$ & R chart is appropriate, you have to construct the charts.

This is not difficult and by following the 8 steps below you will have a robust way to monitor the stability of your process.

## 1. Determine Sample Plan

Determine the sample size, n, and frequency of sampling. Consider cost of sampling, required resources, and balance with minimizing time (and produced units) between measurements. Of course more samples and more frequent measurements is better statistically.

## 2. Collect initial set of samples

Shewhart recommended 100 individual units in 25 samples of 4 each. Basically we want enough samples to create reasonable estimates of the mean values of $\bar{X}$ and R. Keep the data in time sequence following the time of the sample selection, which should be in the same order of manufacture.

## 3. Calculate $\bar{X}$

Calculate the average for each set of samples. This is the $\bar{X}$ for each sample.

## 4. Calculate R

Calculate the range of each set of samples. This is the difference between the largest and smallest value in the sample.

## 5. Calculate $\bar{\bar{X}}$

Calculate the average of the $\bar{X}$‘s. This is the centerline of the $\bar{X}$ control chart.

## 6. Calculate $\bar{R}$

Calculate the average of the R values. This is the centerline of the R control chart.

## 7. Calculate Control Limits

First calculate the R chart limits.

$\displaystyle UC{{L} _{R}}={{D} _{4}}\bar{R}$

$\displaystyle LC{{L} _{R}}={{D} _{3}}\bar{R}$

Note: for a sample size, n, of less than 7 the lower limit is zero.

The ${{D} _{3}}$ and ${{D} _{4}}$ constants are found in tables or calculated with the following formulas.

$\displaystyle {{D} _{3}}=1-\frac{3{{d} _{3}}}{{{d} _{2}}}$

$\displaystyle {{D} _{4}}=1+\frac{3{{d} _{3}}}{{{d} _{2}}}$

where,

$\displaystyle {{d} _{2}}=\int _{-\infty }^{\infty }{\left[ 1-{{\left( 1-{{\alpha } _{l}} \right)}^{n}} \right]}d{{x} _{l}}$

$\displaystyle {{d} _{3}}=\sqrt{2\int _{-\infty }^{\infty }{\int _{-\infty }^{{{x} _{l}}}{\left[ 1-\alpha _{l}^{n}-{{\left( 1-{{\alpha } _{n}} \right)}^{n}}+{{\left( {{\alpha } _{l}}-{{\alpha } _{n}} \right)}^{n}} \right]}}d{{x} _{n}}d{{x} _{l}}-d _{2}^{2}}$

and,

$\displaystyle {{\alpha } _{l}}=\frac{1}{\sqrt{2\pi }}\int _{-\infty }^{{{x} _{l}}}{{{e}^{-\left( \frac{{{x}^{2}}}{2}\ \right)}}}dx$

$\displaystyle {{\alpha } _{n}}=\frac{1}{\sqrt{2\pi }}\int _{-\infty }^{{{x} _{n}}}{{{e}^{-\left( \frac{{{x}^{2}}}{2}\ \right)}}}dx$

n = sample size

A Table of Constants speeds up the calculations.

n A2 D3 D4
2 1.880 0 3.267
3 1.023 0 2.575
4 0.729 0 2.282
5 0.577 0 2.114
6 0.483 0 2.004
7 0.419 0.076 1.924
8 0.373 0.136 1.864
9 0.337 0.184 1.816
10 0.308 0.223 1.777

Be sure to plot the data on the R chart and if not in control, before continuing with building the control chart, work to bring the variability of the process under control.

For the $\bar{X}$ chart limits use

$\displaystyle UCL=\bar{\bar{X}}+{{A} _{2}}\bar{R}$

$\displaystyle LCL=\bar{\bar{X}}-{{A} _{2}}\bar{R}$

where,

$\displaystyle {{A} _{2}}=\frac{3}{{{d} _{2}}\sqrt{n}}$

## 8. Plot the data

With the control limits in place, gather samples, and plot the data. Look for special or assignable causes and adjust the process as necessary to maintain a stable and in control process.

formulas from

2002, Manual on presentation of data and control chart analysis, ASTM International, West Conshohocken, PA.

This entry was posted in II. Probability and Statistics for Reliability and tagged by Fred Schenkelberg. Bookmark the permalink.

## About Fred Schenkelberg

I am an experienced reliability engineering and management consultant with FMS Reliability, a consulting firm I founded in 2004. I left Hewlett Packard (HP)’s Reliability Team, where I helped create a culture of reliability across the organization, to assist other organizations. Given the scope of my work, I am considered an international authority on reliability engineering. My passion is working with teams to improve product reliability, customer satisfaction, and efficiencies in product development; and to reduce product risk and warranty costs. I have a Bachelor of Science in Physics from the United States Military Academy and a Master of Science in Statistics from Stanford University.

## 4 thoughts on “8 steps to Creating a X-bar and R control chart”

• Thanks Dan,

And, Happy Holiday to you!

Cheers,

Fred