Process behavior tool

XmR chart generator

TL;DRPaste values in time order and this generator draws an XmR chart. The X chart shows each value against the average and natural process limits at the average plus or minus 2.66 average moving ranges. The mR chart shows each moving range against an upper range limit of 3.268 average moving ranges. Points beyond a limit are flagged.

Updated · Giacomo Balli

One per line, or separated by commas or spaces on a single line. A label before the number on a line is ignored, so "Jan 920" works. Use a dot for decimals. Up to 1000 values.
Average934Central line, X̄
Average moving range32.63mR̄ over 19 ranges
Upper natural process limit1,020.8X̄ + 2.66 × mR̄
Lower natural process limit847.2X̄ − 2.66 × mR̄
Upper range limit106.643.268 × mR̄

3 values outside the natural process limits and 1 moving range above the upper range limit. Each one is worth a look.

X chart individual values, 20 points
X chart of 20 values with average 934 and natural process limits 847.2 to 1,020.8UNPL1,020.8AVG934LNPL847.214710131619#1: 920#2: 925#3: 830 (below the limit)#4: 855#5: 905#6: 925#7: 945#8: 915#9: 940#10: 940#11: 910#12: 860#13: 865#14: 985#15: 970#16: 940#17: 975#18: 1,000#19: 1,035 (above the limit)#20: 1,040 (above the limit)X chart of 20 values with average 934 and natural process limits 847.2 to 1,020.8UNPL1,020.8AVG934LNPL847.21591317#1: 920#2: 925#3: 830 (below the limit)#4: 855#5: 905#6: 925#7: 945#8: 915#9: 940#10: 940#11: 910#12: 860#13: 865#14: 985#15: 970#16: 940#17: 975#18: 1,000#19: 1,035 (above the limit)#20: 1,040 (above the limit)
mR chart moving ranges, 19 points
Moving range chart with average 32.63 and upper range limit 106.64URL106.64AVG mR32.6314710131619#2: 5#3: 95#4: 25#5: 50#6: 20#7: 20#8: 30#9: 25#10: 0#11: 30#12: 50#13: 5#14: 120 (above the limit)#15: 15#16: 30#17: 35#18: 25#19: 35#20: 5Moving range chart with average 32.63 and upper range limit 106.64URL106.64AVG mR32.631591317#2: 5#3: 95#4: 25#5: 50#6: 20#7: 20#8: 30#9: 25#10: 0#11: 30#12: 50#13: 5#14: 120 (above the limit)#15: 15#16: 30#17: 35#18: 25#19: 35#20: 5

Tap or hover a point to read its value.

  • Point 3 is 830, below the lower limit of 847.2.
  • Point 19 is 1,035, above the upper limit of 1,020.8.
  • Point 20 is 1,040, above the upper limit of 1,020.8.
  • Range 13–14 is 120 (from 865 to 985), above the upper range limit of 106.64.
Data table
#ValueMoving rangeFlag
1920–
29255
383095value below limit
485525
590550
692520
794520
891530
994025
109400
1191030
1286050
138655
14985120range above URL
1597015
1694030
1797535
181,00025
191,03535value above limit
201,0405value above limit

An XmR chart, also called an individuals and moving range chart or a process behavior chart, separates routine variation from changes worth chasing. It needs one number per period, so it suits weekly sales, monthly churn or app launch times that never arrive in subgroups. The sample loaded above is Donald Wheeler's published batch-weight data. For a longer introduction with worked examples from mobile apps, read Being data driven: do you use XmR charts?

How are XmR chart limits calculated?

An XmR chart's central line is the average of the values. Each moving range is the absolute difference between a value and the one before it, so 20 values give 19 ranges. The natural process limits are the average plus and minus 2.66 times the average moving range. The upper range limit is 3.268 times the average moving range.

LineFormula
Average (X̄)sum of values ÷ n
Moving range (mR)|xi − xi−1|
Average moving range (mR̄)sum of moving ranges ÷ (n − 1)
Upper natural process limitX̄ + 2.66 × mR̄
Lower natural process limitX̄ − 2.66 × mR̄
Upper range limit3.268 × mR̄

The moving range chart has no lower limit, because a range of zero is always possible. Compute the limits from the moving range, never from the standard deviation of all the values: a shift in the process inflates the global standard deviation and widens the limits until they hide the shift.

Where do the 2.66 and 3.268 constants come from?

Both XmR constants come from the bias correction for ranges of two values. For subgroups of two, the d2 constant is 1.128, so three sigma equals 3 ÷ 1.128 = 2.660 average moving ranges. The D4 factor for subgroups of two is 3.268. The NIST/SEMATECH e-Handbook writes the same limit as 3 × mR̄ ÷ 1.128.

Walter Shewhart introduced control charts at Bell Telephone Laboratories in the 1920s. Wheeler argues that the limits are a practical filter for signals, not a probability statement, which is why the same 2.66 works for skewed data that is nowhere near normal.

Does this generator reproduce Wheeler's published numbers?

The generator matches Donald Wheeler's figures for his 20 batch weights in "Good Limits From Bad Data (Part I)", Quality Digest, March 1997. He reports an average of 934, an average moving range of 32.63, natural process limits of 847.2 to 1,020.8 and an upper range limit of 106.6. The sample above returns the same four numbers.

It also flags 830, 1,035 and 1,040 as outside the limits, and the jump from 865 to 985, a moving range of 120, above the upper range limit. In the same article Wheeler shows that three standard deviations of the whole set (s = 56.68) give limits of 764 to 1,104, wide enough to hide every one of those values.

What should you do with a point outside the limits?

A point outside the natural process limits is evidence that something changed the process, so look for a cause at that time. Points inside the limits are routine variation, and reacting to each one adds noise. This generator checks the limits only; Wheeler's other detection rules, such as long runs on one side of the average, are not tested.

Once you find and remove a cause, recompute the limits from data collected after the change. Keep the old limits while you are still asking whether the process moved, or every shift gets absorbed into new, wider limits.

Key takeaways

  • Natural process limits are the average plus or minus 2.66 times the average moving range of consecutive values.
  • The upper range limit for the moving range chart is 3.268 times the average moving range, with no lower limit.
  • Never build the limits from the overall standard deviation, because a process shift inflates it and hides the signal.
  • Wheeler's batch-weight data give 847.2 to 1,020.8 and 106.6, and this generator reproduces those figures exactly.

Frequently asked questions

Is an XmR chart the same as an I-MR chart?
Yes. XmR, I-MR, ImR and individuals and moving range chart are four names for one chart. Minitab and most statistics packages say I-MR; Donald Wheeler writes XmR and calls the family process behavior charts. The formulas are identical: the average plus or minus 2.66 average moving ranges, and an upper range limit of 3.268 average moving ranges.
Can I use the median moving range instead of the average?
Yes. Wheeler gives it as a second correct method that resists a few very large ranges. Multiply the median moving range by 3.145 for the natural process limits and by 3.865 for the upper range limit. On his 1997 batch data the median range of 30 gives limits of 839.6 to 1,028.4. This generator uses the average moving range.
Are natural process limits the same as specification limits?
No. Natural process limits are computed from the data and describe what the process does on its own. Specification limits are set by a customer or an engineer and describe what you want it to do. A process can sit inside its natural limits and still miss the specification every week, or the reverse.
Is my data sent anywhere or stored?
The numbers go to this server only to be calculated and drawn, in the same request that returns the chart. They are not written to disk, logged or kept between visits, and there is no account. Reloading the page brings back the sample data, so keep your own copy of anything you paste.

About the author. Giacomo Balli builds iOS apps and small web tools, and wrote this site's guide to XmR charts. The formulas here are checked against Wheeler's articles and the NIST/SEMATECH handbook.

Disclosure: free tool, no sign-up and no affiliation with Donald Wheeler or SPC Press. The sample data are reproduced from Wheeler's 1997 Quality Digest column to show the calculation.