Using data to decide where quality effort should go, and how reliable the product actually is.
π Where this lives: every large service now runs on this principle. An error-tracking system groups thousands of raw exception reports into a ranked list of distinct causes, and the team fixes them in order of frequency and user impact rather than in order of arrival. That is statistical SQA: stop treating defects as individual accidents and treat them as a population with a distribution you can measure and attack. Search "error grouping prioritisation Sentry top issues".
The method
STATISTICAL SQA implies an approach in which the SPECIFICITY of
quality requirements drives the quality assurance process, and
in which quality is MEASURED rather than asserted.
THE FOUR STEPS (Pressman):
1. INFORMATION ABOUT SOFTWARE DEFECTS IS COLLECTED AND
CATEGORISED.
2. AN ATTEMPT IS MADE TO TRACE EACH DEFECT TO ITS UNDERLYING
CAUSE β a specification error, a design flaw, a violation
of standards, poor communication with the customer, and so
on.
3. USING THE PARETO PRINCIPLE (80% of the defects can be
traced to 20% of all possible causes), ISOLATE THE 20% β
the "vital few".
4. ONCE THE VITAL FEW CAUSES HAVE BEEN IDENTIFIED, MOVE TO
CORRECT THE PROBLEMS THAT CAUSED THE DEFECTS.
THE CONCEPTUAL SHIFT: the aim is not to fix these defects but
to STOP PRODUCING THEM. Step 2 β root cause, not symptom β is
where the leverage is, and it is the step most often skipped.
TYPICAL DEFECT CAUSE CATEGORIES (Pressman's list, used for
classification):
IES incomplete or erroneous specification
MCC misinterpretation of customer communication
IDS intentional deviation from specification
VPS violation of programming standards
EDR error in data representation
IMI inconsistent module interface
EDL error in design logic
IET incomplete or erroneous testing
IID inaccurate or incomplete documentation
PLT error in programming language translation of design
HCI ambiguous or inconsistent human-computer interface
MIS miscellaneous
WORKED β a full Pareto analysis. One year of defect data,
classified by cause, and split into SERIOUS / MODERATE / MINOR:
cause total serious moderate minor
ββββββββββββββββββββββββββββββββββββββββ
IES 205 34 68 103
MCC 156 12 68 76
IDS 48 1 24 23
VPS 25 0 15 10
EDR 130 26 68 36
IMI 58 9 18 31
EDL 45 14 12 19
IET 95 12 35 48
IID 36 2 20 14
PLT 60 15 19 26
HCI 28 3 17 8
MIS 56 0 15 41
ββββββββββββββββββββββββββββββββββββββββ
TOTAL 942 128 379 435
STEP 1 β RANK BY TOTAL COUNT and compute cumulative
percentage:
IES 205 21.8% cumulative 21.8%
MCC 156 16.6% 38.3%
EDR 130 13.8% 52.1%
IET 95 10.1% 62.2%
PLT 60 6.4% 68.6%
IMI 58 6.2% 74.7%
MIS 56 5.9% 80.7% β the 80% line
IDS 48 5.1% 85.8%
EDL 45 4.8% 90.6%
IID 36 3.8% 94.4%
HCI 28 3.0% 97.3%
VPS 25 2.7% 100.0%
SEVEN of twelve causes account for 80.7% of all defects.
Not quite the textbook 20%, which is normal β the Pareto
principle is a heuristic, not a law. But the top THREE
causes alone (IES, MCC, EDR) account for 52.1%, and that is
genuinely actionable.
STEP 2 β BUT RANK BY SERIOUSNESS AND THE ANSWER CHANGES:
IES 34 serious 26.6% of all serious
EDR 26 20.3% cum 46.9%
PLT 15 11.7% cum 58.6%
EDL 14 10.9% cum 69.5%
MCC 12 9.4% cum 78.9%
IET 12 9.4% cum 88.3%
IMI 9 7.0% cum 95.3%
HCI 3, IID 2, IDS 1, VPS 0, MIS 0
LOOK AT WHAT MOVED. MIS was 3rd-largest by TOTAL count
(56 defects) but contributes ZERO serious defects. PLT and
EDL are mid-ranked by count but 3rd and 4th by seriousness.
RANKING BY RAW COUNT WOULD SEND EFFORT TO THE WRONG PLACE.
THE WEIGHTED APPROACH β a defect index. Weight each severity:
serious = 10, moderate = 3, minor = 1
index(IES) = 34Γ10 + 68Γ3 + 103Γ1 = 647
index(EDR) = 26Γ10 + 68Γ3 + 36Γ1 = 500
index(MCC) = 12Γ10 + 68Γ3 + 76Γ1 = 400
index(IET) = 12Γ10 + 35Γ3 + 48Γ1 = 273
index(PLT) = 15Γ10 + 19Γ3 + 26Γ1 = 233
index(EDL) = 14Γ10 + 12Γ3 + 19Γ1 = 195
index(IMI) = 9Γ10 + 18Γ3 + 31Γ1 = 175
index(IDS) = 1Γ10 + 24Γ3 + 23Γ1 = 105
index(MIS) = 0Γ10 + 15Γ3 + 41Γ1 = 86
index(HCI) = 3Γ10 + 17Γ3 + 8Γ1 = 89
index(IID) = 2Γ10 + 20Γ3 + 14Γ1 = 94
index(VPS) = 0Γ10 + 15Γ3 + 10Γ1 = 55
TOTAL = 2,852
top three by index: IES 647 + EDR 500 + MCC 400 = 1,547
= 54.2% of the weighted total
STEP 3 β ACT ON THE VITAL FEW. And note that the actions are
PROCESS changes, not code fixes:
IES (incomplete/erroneous specification, 647)
β requirements reviews with a completeness checklist;
formal acceptance-criteria sign-off. This is the
requirements-validation activity from ACtE0801, and the
data says it is the single highest-value investment.
EDR (error in data representation, 500)
β a reviewed data dictionary; explicit units and types in
interface specifications β precisely the interface
specification discipline.
MCC (misinterpretation of customer communication, 400)
β prototypes and scenario walkthroughs with the
customer; written confirmation of decisions.
THREE PROCESS CHANGES ADDRESSING 54% OF WEIGHTED DEFECTS.
That is what statistical SQA is for, and it is why the method
ends in process improvement rather than in a bug list.
Six Sigma, and statistical usage testing
SIX SIGMA β the most widely used strategy for statistical
quality assurance in industry, originating at Motorola. The term
derives from six standard deviations: at most 3.4 defects per
million opportunities.
THE CORE METHODOLOGY, DMAIC, for existing processes:
DEFINE customer requirements, deliverables and project
goals via well-defined methods of customer
communication
MEASURE the existing process and its output to determine
current quality performance (collect defect
metrics)
ANALYSE defect metrics and determine the vital few causes
IMPROVE the process by eliminating the root causes of
defects
CONTROL the process to ensure that future work does not
reintroduce the causes of defects
DMADV, for developing NEW processes:
DEFINE Β· MEASURE Β· ANALYSE Β· DESIGN Β· VERIFY
Note that ANALYSE is the Pareto step above, and IMPROVE and
CONTROL are what distinguish this from merely measuring.
Without CONTROL, the causes come back.
STATISTICAL USAGE TESTING β the Cleanroom counterpart, and a
genuinely different idea from ordinary testing.
THE INSIGHT: not all defects matter equally, because not all
code is used equally. Testing should therefore sample the
input space according to how USERS ACTUALLY USE the system, not
uniformly and not according to what is easy to test.
THE METHOD:
1. build a USAGE MODEL β a probability distribution (often a
Markov chain) over the operations users perform
2. generate test cases by RANDOMLY SAMPLING from that
distribution
3. run them, and measure the failure rate
4. from the observed failures, CERTIFY the reliability
statistically β producing an MTTF estimate with a
confidence interval
WORKED β why usage weighting changes the priority:
operation usage frequency defects found
βββββββββββββββββββββββββββββββββββββββββββββββββ
status lookup 62% 4
new application 21% 9
fee payment 11% 6
annual report 4% 11
bulk export 2% 14
BY RAW DEFECT COUNT, bulk export (14) looks like the worst
module and the obvious place to invest.
BY EXPECTED USER IMPACT β defects Γ usage:
status lookup 4 Γ 0.62 = 2.48
new application 9 Γ 0.21 = 1.89
fee payment 6 Γ 0.11 = 0.66
annual report 11 Γ 0.04 = 0.44
bulk export 14 Γ 0.02 = 0.28
total expected impact = 5.75
STATUS LOOKUP IS THE TOP PRIORITY and bulk export the
LOWEST, which is the exact reverse of the raw-count ranking.
Four defects in a path used by 62% of requests will be met by
far more users than fourteen defects in a path used by 2%.
THIS IS THE WHOLE ARGUMENT for usage-based testing, and it
generalises: RELIABILITY AS EXPERIENCED BY USERS is a
property of the defect distribution WEIGHTED BY THE USAGE
DISTRIBUTION, never of the defect count alone.
RELIABILITY CERTIFICATION then follows: if random usage-model
sampling produces n test cases with f failures, the observed
failure rate f/n estimates the probability a real user
interaction fails β which is POFOD from the metrics topic, now
with a defensible statistical basis rather than a guess.
THE LIMITATIONS, honestly:
Β· the usage model must be RIGHT, and early in a product's
life nobody knows the usage distribution
Β· usage changes over time, so the model needs maintaining
Β· rare-but-catastrophic paths are UNDER-WEIGHTED by
construction. A safety-critical shutdown path may be used
0.001% of the time and still matter more than everything
else β so usage weighting must be combined with a
criticality analysis, never used alone.
Β· defect classification is subjective; two engineers may
assign different causes to the same defect, which
introduces noise into the Pareto analysis. Agreeing the
categories and reviewing classifications matters.
The MIS row is the lesson in miniature: it is the third-largest defect category by raw count and contributes zero serious defects. Rank by count and you would send your best engineers to fix the least consequential thing on the list. Severity weighting and usage weighting both exist to prevent exactly that mistake.
π Go further: the operational descendant of statistical usage testing is the error budget. If your availability objective is 99.9%, you are permitted 43.2 minutes of failure per month β and that budget is a currency: while it is unspent you may ship features aggressively, and when it is exhausted the team switches to reliability work until it refills. It converts "how reliable should we be?" from an argument between engineering and product into a measured, self-regulating policy, and it is statistical SQA applied to a live service. Search "SRE error budget policy burn rate".
π‘ Exam angle: list the four steps of statistical SQA (collect and categorise, trace to underlying cause, apply the Pareto principle to isolate the vital few, correct the causes) and state the Pareto principle as 80% of defects from 20% of causes. Know the defect cause categories β IES, MCC, IDS, VPS, EDR, IMI, EDL, IET, IID, PLT, HCI, MIS. Be ready to perform a Pareto analysis from a table: rank by count, compute cumulative percentages, then re-rank by seriousness and comment on the difference β that comparison is the marks. Give Six Sigma as 3.4 defects per million opportunities with the DMAIC and DMADV steps, and explain statistical usage testing.
Syllabus points
Statistical SQA
Create a free account to tick topics off, take notes as you read, watch the video lessons and get a day-by-day study plan built around your exam date.
Related topics in Testing, Cost Estimation, Quality & Configuration Management