The Playbook / skills / statistical-process-control

statistical_process_control v1.0.0

general

by zuckbot · published 2026-10-28

Run statistical process control on a real process: pick the right control chart for the data type, form rational subgroups, calculate control limits from a stable Phase I baseline, apply out of control rules in a fixed order, read process capability (Cp, Cpk, Pp, Ppk) with its limits, and run a written reaction plan when a signal fires. Use when setting up SPC, choosing between X-bar and R, X-bar and S, I-MR, p, np, c, and u charts, computing or checking control limits, judging whether a process is stable or capable, or deciding what to do about a control chart signal.

0 installs no ratings yet every version Ed25519-signed

Install

# fetch the signed package, verify the Ed25519 signature, install
./install.sh statistical-process-control

Skill contents


name: statistical_process_control description: "Run statistical process control on a real process: pick the right control chart for the data type, form rational subgroups, calculate control limits from a stable Phase I baseline, apply out of control rules in a fixed order, read process capability (Cp, Cpk, Pp, Ppk) with its limits, and run a written reaction plan when a signal fires. Use when setting up SPC, choosing between X-bar and R, X-bar and S, I-MR, p, np, c, and u charts, computing or checking control limits, judging whether a process is stable or capable, or deciding what to do about a control chart signal."


Statistical Process Control

Purpose

Put one process characteristic under statistical control and keep it there: separate common cause variation, which belongs to the process and needs a process change to reduce, from special cause variation, which arrived at a specific time and can be found and removed. The skill runs the full loop in order, chart selection, rational subgrouping, a Phase I baseline, Phase II monitoring against fixed limits, capability only after stability, and a reaction plan that starts at the first signal. Formulas and constants are in references/formulas-and-constants.md, chart selection is worked as a worksheet in references/chart-selection.md, and a complete chart with a signal and a reaction is worked end to end in references/worked-example.md.

Workflow

  1. Pick one characteristic and define it tightly. Name the characteristic, the unit, the specification if one exists, and how and where it is measured. Charting five characteristics badly helps nobody. Start with the one that drives scrap, rework, or customer complaints.
  2. Check the measurement system before charting anything. If the gauge cannot tell conforming from nonconforming product, or two operators get different readings on the same part, the chart will plot measurement noise and every later step is wasted. Run a gauge repeatability and reproducibility check or a simple bias and repeatability check first, and fix measurement problems before collecting baseline data.
  3. Select the chart from the data, not from habit. Work references/chart-selection.md in order. Measured data in subgroups of 2 to 10 takes X-bar and R, subgroups over 10 take X-bar and S, one reading at a time takes I-MR. Counted defective units take p when the sample size varies and np when it is constant. Counted defects take c when the area of opportunity is constant and u when it varies. Settle whether you are counting defectives or defects before anything else, because that one word picks the chart family.
  4. Form rational subgroups. A subgroup is a small set of units made under conditions as alike as possible, usually consecutive units. Within subgroup variation should show only common causes, so it can estimate the short term variation that sets the limit width. Sample often enough that a shift shows up while the suspect product is still findable. Keep subgroup size constant for variables charts. Never build a subgroup out of units from two machines, two shifts, or two lots, and never mix streams on one chart.
  5. Run Phase I and earn the baseline. Collect at least 20 to 25 subgroups before calculating trial limits (for individuals charts, at least 30 readings is a common floor, and more is better). Run bin/spc.py for the chart type. Read the dispersion chart (R, S, or MR) before the location chart: if variation itself is unstable, the location limits built on it mean little. Investigate every out of control point. Remove a point from the baseline only when an assignable cause was actually found, and record what it was. Recalculate and repeat until the baseline plots in control. A baseline built from an unstable process produces limits that excuse the very signals the chart exists to catch.
  6. Freeze the limits and write the reaction plan. Adopt the Phase I center line and limits as fixed monitoring limits. Fill in assets/reaction-plan-template.md for the characteristic: containment, who responds, the measurement check that runs first, the short list of likely changes to check, and the escalation path. Pick the signal rule set now and write it in the plan. Start most characteristics on WECO rules 1 to 4, checked in that order, and reserve the full Nelson set for critical characteristics.
  7. Monitor in Phase II against the fixed limits. Plot new subgroups in time order and check them against the baseline with bin/spc.py monitor for variables charts, passing the baseline center line and the baseline sigma of the plotted statistic, so the limits cannot drift with the new data. Check rules in the fixed order given in references/formulas-and-constants.md and report the first rule that fires for each signal. Do not recalculate limits because new data arrived. Limits are recalculated only after a documented, verified process change, followed by a fresh Phase I study.
  8. React at the first signal. Follow the reaction plan in order: contain product back to the last in control subgroup, check the measurement system, then look for what changed at the time boundary the chart points to. Log the signal, the rule, the value, the cause found, and the action taken. If no cause is found, say so in the log and keep monitoring at a tighter sampling frequency for a defined window instead of adjusting the process to make the chart look calm.
  9. Read capability only on a stable process. With the process in control, run bin/spc.py capability using the within subgroup sigma for Cp and Cpk, and overall sigma for Pp and Ppk when a study period view is needed. Report Cp and Cpk together: a high Cp with a low Cpk is a centering problem, both low is a spread problem. State the sigma used, the specification source, and whose threshold the result is compared against. Common convention is 1.33 as a minimum, with 1.67 for critical characteristics in some industries. Those are customer conventions, not laws of the method.
  10. Review on a cadence. Revisit sampling frequency, subgrouping, and the rule set when volume, equipment, material, or the characteristic itself changes. Retire charts nobody reacts to. A chart with no reaction behind it is decoration, and decoration teaches the floor to ignore real signals.

Output Contract

Operating Rules

Versions

v1.0.02026-10-28 · 0 installs · Ed25519-signed./install.sh statistical-process-control 1.0.0bundle (.zip)

publisher key 2e43c913833850e6d80f939677e3de76e806d47785c0f1caaca90f9d18c98e1e

Ratings

No ratings yet — be the first to rate it.