01 / 21

Quality Assurance
Sampling

Learn how businesses use statistical sampling to inspect products, control defect rates, and make data-driven accept/reject decisions using the sample proportion \( \hat{p} \).

Business Statistics

What Is QA Sampling?

In manufacturing and services, it is impractical to inspect every single item produced. Instead, businesses select a representative subset (a sample) and use the results to judge the quality of the entire batch or lot.

Core Vocabulary

Lot
The entire batch of items produced or received for inspection.
Sample (\( n \))
A subset of \( n \) items drawn from the lot for testing.
Defect Rate (\( p \))
The true proportion of defective items in the lot (often unknown).
\( \hat{p} \)
Sample proportion: \( \hat{p} = \frac{d}{n} \) where \( d \) = defectives found.
AQL
Acceptable Quality Level: the maximum defect rate the buyer will tolerate.

Why Sampling Matters

LOT (\(N = 500\))
DRAW
SAMPLE (\(n = 50\))
Accept or Reject?

The Sample Proportion Formula

When sampling from a large lot, \( \hat{p} \) is an unbiased estimator of the true defect rate \( p \). As the sample size \( n \) increases, \( \hat{p} \) becomes a more precise estimate of \( p \).

Acceptance Sampling Rule

Draw sample of \(n\) items
Count defectives \(d\)
\( d \le c \text{?} \)
ACCEPT Yes REJECT No

Sampling vs. 100% Inspection

Sampling 100% Inspection
Cost Low High
Time Fast Slow
Destructive Tests Practical Impossible
Accuracy Estimate with error Exact count
Risk of Error Producer and Consumer Risk None (if perfect)

Types of Sampling Plans

Single
Draw one sample of size \( n \). Decide immediately: accept or reject based on defectives \( d \) vs. acceptance number \( c \).
Double
Draw a first sample. If inconclusive, draw a second sample and combine results before deciding.
Sequential
Items tested one at a time. After each item, decide: accept, reject, or keep testing. Minimizes average sample size.

Producer and Consumer Risk

\( \alpha \) : Producer's Risk
Probability of rejecting a lot that is actually good (meets AQL). Also called a Type I error. Typically set at \( \alpha = 0.05 \).
\( \beta \) : Consumer's Risk
Probability of accepting a lot that is actually bad (exceeds a tolerable defect rate). Also called a Type II error. Typically set at \( \beta = 0.10 \).

How to Apply: Step by Step

1
Define the lot. Identify the batch size \( N \) and the Acceptable Quality Level (AQL).
2
Choose \( n \) and \( c \). Select a sample size \( n \) and acceptance number \( c \) using a sampling table or standard (e.g., ANSI/ASQ Z1.4).
3
Draw a random sample. Use a random method (random number table, software) to select \( n \) items from the lot.
4
Inspect and count. Test each item. Record the number of defectives \( d \).
5
Decide. If \( d \le c \), accept the lot. If \( d > c \), reject it.

Example 1: Phone Charger Inspection

A shipment of 1,000 phone chargers arrives. The buyer's AQL is 2%. The sampling plan specifies: \( n = 80 \), \( c = 3 \). The inspector finds \( d = 2 \) defectives.

Example 2: LED Bulb Factory

A factory produces 5,000 LED bulbs per day. Quality control uses \( n = 200 \), \( c = 5 \). Today's sample reveals \( d = 8 \) defectives.

Example 3: Choosing Sample Size

A food company wants the margin of error for its defect rate estimate to be at most \( E = 0.02 \) (2 percentage points) at 95% confidence. Past data suggests \( p \approx 0.05 \). How large a sample is needed?

The OC Curve

The Operating Characteristic (OC) Curve shows the probability of accepting a lot as a function of the true defect rate \( p \). It is the signature of a sampling plan.

0 0.25 0.50 0.75 1.00 0 0.02 0.04 0.06 0.08 0.10 True Defect Rate p P(Accept) AQL
\( 1 - \alpha \approx 0.93 \)

Common Mistakes

✕ Non-Random Sampling
Picking items only from the top of a box introduces selection bias. Always use a random selection method.
✕ Confusing \( p \) and \( \hat{p} \)
\( p \) is the true (unknown) defect rate. \( \hat{p} \) is the sample estimate. They are not the same.
✕ Too Small a Sample
Using too few items gives a wide margin of error and unreliable decisions. Always follow the sampling plan's \( n \).

Summary of Key Concepts

Concept Symbol Meaning
Lot size \( N \) Total items in the batch
Sample size \( n \) Items drawn for inspection
Acceptance number \( c \) Max defectives to accept lot
Defectives found \( d \) Observed defective count
Sample proportion \( \hat{p} = \frac{d}{n} \) Estimated defect rate
AQL — Maximum tolerable defect rate
Producer's risk \( \alpha \) Rejecting a good lot (Type I)
Consumer's risk \( \beta \) Accepting a bad lot (Type II)

Question 1 of 5

A sample of \( n = 100 \) items yields \( d = 4 \) defectives. What is the sample proportion \( \hat{p} \)?

Question 2 of 5

A sampling plan uses \( n = 50 \) and \( c = 2 \). A sample reveals \( d = 3 \) defectives. What is the decision?

Question 3 of 5

The producer's risk \( \alpha \) is best described as:

Question 4 of 5

Which of the following would decrease the standard error of \( \hat{p} \)?

Question 5 of 5

Why is sampling preferred over 100% inspection when the test is destructive?