Calculator overview
Inputs and outputs
This summary comes from the calculator's published input and output contract.
Inputs
- Subgroup Size
-
Unit 2 to 5 Default 5 Range 2 to 5
About this input
The number of measurements in each subgroup, from 2 to 5. It selects the control chart constants used to turn the average range into control limits.
- Upper Specification Limit
-
Unit units Default 10.4
About this input
The highest value the product may have and still conform, in the measured units. Used with the estimated sigma to report process capability, not for the control limits.
- Lower Specification Limit
-
Unit units Default 9.6
About this input
The lowest value the product may have and still conform, in the measured units. Used for capability, not for the control limits.
- Subgroup Measurements
-
Default 25 rows
About this input
One row per subgroup, holding the individual measurements taken at that sampling time. The tool computes each subgroup's mean and range, then builds the X-bar and R control limits from the set.
Column Range or allowed values Subgroup Not declared x1 Not declared x2 Not declared x3 Not declared x4 Not declared x5 Not declared
Outputs
- Points Out Of Control Averages
-
Unit count
About this output
How many subgroup means fall outside the averages control limits, in count. More than zero means the process average is not stable.
- Points Out Of Control Ranges
-
Unit count
About this output
How many subgroup ranges fall outside the range control limits, in count. More than zero means the within-subgroup spread is not stable.
- Minimum Process Capability Index
-
Unit index
About this output
Cpk, the capability index accounting for how far the process is off centre, as an index. Values above 1.33 are commonly treated as capable.
- Model Status
-
No unit declared
About this output
The overall check on your entries, shown above the results. It reads OK when the inputs are usable, NOT VALID with a reason when an entry makes the model meaningless, or CHECK with a reason when a result is valid but worth a second look. Read it before you trust the numbers below.
- Process Capability Index
-
Unit index
About this output
Cp, the specification width divided by six times the estimated sigma, as an index. It assumes the process is centred and is only meaningful once the chart shows control.
- Upper Control Limit Averages
-
Unit units
About this output
The upper control limit for the subgroup averages, in the measured units. A subgroup mean above it signals the process may be out of control.
- Upper Control Limit Ranges
-
Unit units
About this output
The upper control limit for the subgroup ranges, in the measured units. A range above it signals a change in within-subgroup variation.
- Subgroup Size In Use
-
Unit count
About this output
The subgroup size the calculations actually used, in count, after reading the entered data. The declared range is 2 to 5 because the control-chart constants are tabulated to five; confirm it matches the size you intended.
- Total Parts Per Million Out Of Specification
-
Unit ppm
About this output
The estimated defect rate beyond the two specification limits, in parts per million, from the normal model at the estimated mean and sigma. It is an estimate, not a measured count.
- Control Chart Constant D2
-
Unit constant
About this output
The d2 bias-correction constant for the subgroup size, derived by integrating the range distribution rather than read from a published table. It converts the average range into an estimate of sigma.
- Control Chart Constant D3
-
Unit constant
About this output
The D3 constant for the subgroup size, which sets the lower control limit for the ranges. It is zero for small subgroups.
- Average Range
-
Unit units
About this output
The average of the subgroup ranges, in the measured units, taken over the COMPLETE subgroups only: a row with fewer readings than the subgroup size is refused rather than averaged, because the d2 constant assumes exactly n readings. It drives both the range control limits and the estimate of sigma.
- Control Chart Constant A2
-
Unit constant
About this output
The A2 constant for the subgroup size, which sets the width of the averages control limits from the average range.
- Control Chart Constant D4
-
Unit constant
About this output
The D4 constant for the subgroup size, which sets the upper control limit for the ranges.
- Lower Control Limit Averages
-
Unit units
About this output
The lower control limit for the subgroup averages, in the measured units. These limits describe the process voice, not the specification.
- Lower Control Limit Ranges
-
Unit units
About this output
The lower control limit for the subgroup ranges, in the measured units. It is zero for small subgroups, where the D3 constant is zero.
- Estimated Sigma From The Range
-
Unit units
About this output
The estimate of the process standard deviation, in the measured units, found as the average range divided by d2. It is a within-subgroup estimate, not the standard deviation of all the readings.
- Grand Average
-
Unit units
About this output
The average of all the subgroup means, in the measured units. It is the centre line of the averages chart.
What it is
The Control Chart Calculator sets up X-bar and R charts from measurement data. You enter one row per subgroup, each holding the individual measurements taken at that sampling time, and it computes the centre lines and control limits for both charts, counts any points falling outside them, estimates the process standard deviation from the average range, and reports the capability indices against your specification limits.
Measurements are in whatever units you are working in; the tool carries them through unchanged. Subgroup sizes from 2 to 5 are supported.
Use it to establish control limits from a sample of subgroups and to see whether the process was stable while they were collected. Control limits describe the process; they are not specification limits and the tool keeps the two strictly apart.
Methodology
Purpose and model boundary
This calculator builds X-bar and R control charts from rational subgroups, estimates within-subgroup process variation from the average range, and reports two-sided Cp/Cpk and normal-model out-of-specification PPM against entered specification limits. The range chart is interpreted first because unstable within-subgroup variation invalidates the basis of the X-bar limits and capability estimate.
The workbook applies only the basic point-beyond-a-control-limit signal. It does not test runs, trends, cycles, stratification, mixtures, or other supplementary SPC rules, and it does not substitute specification limits for control limits.
Inputs and units
- Subgroup size,
nis an integer from 2 through 5. - Subgroup measurements contains up to 25 rows. Every used row must contain exactly
nnumeric readings; unused rows remain blank. The subgroup identifier is fixed and not part of the arithmetic. - USL and LSL use the same measurement unit as the grid and must satisfy
USL > LSL.
Columns beyond the selected subgroup size are not part of that row's subgroup. Inputs and results therefore require one consistent physical unit throughout.
Governing relationships
For complete subgroup i, the workbook computes its mean xbar_i and range R_i = max(x_ij) - min(x_ij). Across all complete subgroups,
xbarbar = average(xbar_i);Rbar = average(R_i);UCL_xbar = xbarbar + A2 * Rbar;LCL_xbar = xbarbar - A2 * Rbar;UCL_R = D4 * Rbar;LCL_R = D3 * Rbar;sigma_within = Rbar / d2.
The workbook derives d2 and the range-distribution spread by numerical integration for the selected n; A2 = 3 / (d2 * sqrt(n)), D4 = 1 + 3*d3/d2, and D3 = max(0, 1 - 3*d3/d2).
Capability is calculated from the within-range estimate:
Cp = (USL - LSL) / (6 * sigma_within);Cpu = (USL - xbarbar) / (3 * sigma_within);Cpl = (xbarbar - LSL) / (3 * sigma_within);Cpk = min(Cpu, Cpl).
Out-of-specification PPM is the sum of the two normal-tail probabilities beyond LSL and USL using xbarbar and sigma_within.
Calculation sequence
- Clamp the workbook subgroup-size selector to the implemented range and count numeric readings in each row.
- Reject partial used rows; retain only rows with exactly
nvalues and require at least two complete subgroups. - Calculate each complete row's mean and range, then
xbarbarandRbar. - Select the derived constants for
n, calculate X-bar/R limits, and count points outside each pair of limits. - Estimate within sigma from
Rbar/d2, calculate capability indices and normal-tail PPM, then evaluate status with range-chart signals before average-chart signals.
Outputs and interpretation
The X-bar centre and limits describe between-subgroup movement of the mean; the R chart describes within-subgroup variation. A point outside a limit is a signal for investigation, not proof of a particular cause. Cp compares specification width with estimated short-term spread and ignores centring. Cpk includes the distance to the nearer specification limit. Capability should be interpreted only after the charts support stability.
Validation and status logic
The workbook evaluates status in this order:
| Condition | Returned status |
|---|---|
Any used row contains fewer than n numeric values |
NOT VALID: a subgroup row is incomplete; enter exactly the subgroup size in every used row |
| Fewer than two complete subgroups | NOT VALID: at least two complete subgroups are needed |
USL <= LSL |
NOT VALID: the upper specification limit must exceed the lower |
Rbar <= 0 |
NOT VALID: the average range is zero, check the data |
| Any R-chart point is outside its limits | CHECK: the range chart has points out of control; fix that before reading the averages chart |
| Any X-bar point is outside its limits | CHECK: the averages chart has points out of control |
Cpk < 1.00 |
CHECK: Cpk is below 1.00 |
| None of the above | OK |
This calculator also bounds the subgroup-size control to 2 through 5 and validates grid shape before the workbook call.
Assumptions and limitations
The method assumes rational, independent subgroups of the same size, a stable process, and an approximately normal continuous measurement for the PPM calculation. The range-based sigma estimator is efficient for the small subgroup sizes implemented here but is not a substitute for a study of long-term drift. Only the outside-limit rule is applied; the absence of flagged points does not establish control under other SPC rules. Specification limits are externally defined conformance boundaries and play no role in setting the control limits. A minimum of two subgroups is computationally sufficient but often not sufficient evidence for a production decision.
Restrictions and non-computing states
The workbook supports only the authored subgroup-size range and the outside-limit rule. It does not evaluate supplementary run, trend, zone, or pattern rules. Invalid subgroup grids or invalid specification-limit combinations produce a non-computing state identified by the status message.
Errors and warnings
A rejected entry indicates an invalid control value or invalid grid entry before the model ran. Workbook NOT VALID means the dataset cannot support the X-bar/R calculation. Workbook CHECK means the calculation exists but a control or capability signal needs attention. A calculation-service or network failure is not an out-of-control point.
References
The workbook derives its relations rather than reproducing any table, chart or figure from a specification, standard or agency publication. The control-chart constants are obtained by integrating the distribution of the range for the subgroup size, not read from a published table, and each is reported on the page so the derivation can be checked against any source you trust.
- National Institute of Standards and Technology. NIST/SEMATECH e-Handbook of Statistical Methods, X-bar and R chart formulas. https://itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm
- Wikipedia. Control chart, for the underlying method and its history. https://en.wikipedia.org/wiki/Control_chart
- Wikipedia. Process capability index, for
CpandCpkand their assumptions. https://en.wikipedia.org/wiki/Process_capability_index
Specification limits are yours to supply and carry no authority from this tool. The capability figures depend entirely on them, and on the assumption that the measurements are normally distributed.
Additional source notes migrated from Methodology
The workbook derives d2, A2, D3, and D4 from the range distribution rather than reproducing a published control-chart table, and uses the standard X-bar/R and Rbar/d2 relationships shown above. The page's References section carries the numerical-method and licensing details.
Frequently asked questions
What is the difference between a control limit and a specification limit?
Should I read the control charts or the capability indices first?
Why is the lower control limit on the range chart zero?
Why is Cpk lower than Cp?
Why does the tool refuse a subgroup row that is partly filled?
Does a process inside its control limits mean nothing is wrong?
Found a problem, or have an idea?
Tell us if a result looks wrong, a label is unclear, or something is missing. We read every message.
LogicCommons is in beta. If a result, label, or reference looks wrong, tell us here; we read every message.