Judgement by Sampling (2)

A. F. BISSELL

In the previous article, we considered some of the implications of assessing the quality of a batch of items, in respect of the incidence of some minor defect (slotless screws, for example), on the basis of a sample of the items. In particular, we considered the plan:

Take a sample of 20 items, and accept (the whole batch) provided that not more than one defective item occurs in the sample. If two or more defectives occur, reject the batch. Provided that the 20 items were a random sample from a batch of exactly 100, we found that if the batch contained just two defectives, i.e. 2% there was a probability of 003838… that such a batch would be rejected on the evidence of a sample of 20, and hence a complementary probability of 0.96161 … that such a batch would be rejected. This appears reasonable if we consider 200 of defectives to be an acceptable level of quality - it does not appear unduly harsh on the producer meeting this standard to have about one batch in 26 rejected (say to be 100% sorted and rectified). However, a less satisfactory aspect of this procedure is that if a batch contains as many as 10% items defective, there is still a probability of about 0.363 that it would be judged acceptable by the sample evidence.

In fact, for any hypothetical batch quality, it is very straightforward though tedious to calculate the probability of batch acceptance or rejection. The resulting set of probabilities, especially when presented as a graph of acceptance probability against hypothetical batch quality, is known as the Operating Characteristic of the sampling plan. For the plan with N (batch size) = 100, n (sample size) = 20, and with a and r (acceptance and rejection numbers) of 1 and 2 respectively, the values of A and B (numbers of acceptable and defective items in the batch) may be represented as Np and Nq, where p is the proportion of defective items in the batch and q = 1—p.

Extending the procedure indicated in the previous article, we now write:

The probability of acceptance may be evaluated for any hypothetical value of p, and indeed for any other batch and sample sizes (N, n) and any other acceptance number a (with r = a + 1). In the present example, some of the resulting values are: Operating Characteristic of sampling plan n = 20, a = 1, r = 2 for batch size N = 100.
 
p
Np
Pr (accept)
0
0
10
0.01
1
1.0*
0.02
2
0.9616
0.03
3
0.8989
0.04
4
0.8224
0.05
5
0.7395
0.06
6
0.6554
0.08
8
0.4972
0.10
10
0.3630
0.15
15
0.1453
0.20
20
0.0498

* With only 1 defective in the batch, obviously not more than one can be found in the sample!

The Operating Characteristic curve is shown below, and provides a means of assessing the relative chances of batch acceptance or rejection for any hypothetical quality level—for example, if a batch actually contains just 8 defectives, there are roughly equal chances of acceptance or rejection, so that for this sampling plan and a batch size of 100, 8% is not surprisingly called the "Indifference Quality Level".

There are two ways in which we may wish to extend this characterisation of a sampling plan. One is to examine the effects of changing the sample size, or the acceptance rule (or both); the other is to evaluate similar plans for other batch sizes. Suppose, for example, we apply the above plan (n = 20, a = 1, r = 2) to a batch of 200 items, or even to an infinitely large batch. It is found that in fact, provided the sample does not represent more than about 2000 of the items in the batch, the size of batch has little effect on the operating characteristic. For very large batches, moreover, the calculations become much less tedious, because the probabilities of 0, 1, 2, etc. defectives occurring in a sample of size n taken from an infinite population can be obtained from the Binomial distribution

Pr(X = x) = 

where p is the ‘population’ proportion defective and q = 1 — p. Further, where p is small (for practical purposes, not more than 0.1 (10% 'defective’)), the even simpler Poisson distribution

Pr(X = x) = e-mmx/x!

may be used, setting m = np

As a comparison of these alternatives, let us examine some values on the Operating Characteristic curve of our original sampling plan, using the various procedures outlined above.

Operating Characteristic of sampling plan n = 20, a = 1, r = 2. Batch sizes 100, 200

.
 
Proportion defective in batch Acceptance probabilities for stated batch size Calculations using Poisson approximation
(p)
100
200
infinity *
m = np
Pr(acceptance)
0
1.0000
1.0000
1.0000
0
1.0000
0.02
0.9616
0.9494
0.9401
0.4
0.9384
0.05
0.7395
0.7372
0.7358
1.0
0.7358
0.1
0.3630
0.3782
0.3912
2.0
0.4060
0.15
0.1453
0.1609
0.1756
3.0
n/a p>0.01
0.20
0.0498
0.0595
0.0692
4.0
n/a p>0.01

* Using Binomial distribution.

We now have a simple yet powerful means of comparing the performance of alternative sampling plans, and may turn to considering other possibilities in place of the original plan, which appears not to discriminate very effectively between good and poor quality batches. Assuming that the batch size is large enough to use the Binomial distribution, let us consider the alternatives:

i     n = 20, a = 1, r = 2 (the original plan);
ii.   n = l0, a = 0, r = 1 (where the ratio r/n remains as in (i) but the sample size is halved);
iii.  n = 50, a = 5, r = 6 (where the ratio a/n remains as in (i) but the sample size is doubled);
iv.  n = 20, a = 0, r = 1 (where the original sample size is retained, but the acceptance rule is tighter).

The Operating Characteristics are tabulated below and sketched in Fig. 2.

It is apparent that plan (ii) is much poorer from both the producer’s and consumer’s viewpoint than scheme (i) - it gives much higher risks both of rejection of good batches and acceptance of bad ones. Scheme (iv) is better from the consumer’s angle, but harsh on the producer in that even good batches (at about 2% defective) have only a 2/3 chance of acceptance. Scheme (iii) gives better discrimination, but obviously requires greater effort in sampling and testing or inspection, which may be expensive or inconvenient.

Operating Characteristics of four sampling plans.
 
Proportion defective (in large batch) Pr (acceptance) for plans with stated parameters.
p
n=20
a=1
r= 2
n=l0
a=0
r= 1
n=40
a= 2
r= 3
n=20
a= 0
r= 1
0.00
1.0000
1.0000
1.0000
1.0000
0.01
0.9831
0.9044
0.9925
0.8179
0.02
0.9401
0.8171
0.9543
0.6676
0.05
0.7358
0.5987
0.6767
0.3585
0.1
0.3912
0.3487
0.2228
0.1216
0.15
0.1756
0.1969
0.0486
0.0388
0.2
0.0692
0.1074
0.0079
0.0115

Binomial method used throughout.

Thus in real life much thought needs to be given to the choice of sampling plan for a particular application. Indeed, there are volumes of plans with recommendations on how they should be chosen, for example in British Standard 6001 (BS 6000, a companion standard, explains the plans and their selection and use). They are widely used in industry, often forming the basis of contracts, and are particularly important in supplying government departments. In a later article, the use of such plans in the administration of Weights and Measures Law will be described.

One point which has been glossed over in the preceding account has been that of the selection of the sampled items from the batch. The calculations for the Operating Characteristic (and hence the confidence of both supplier and consumer) hinge on the assumption that all samples of the appropriate size have the same probability of occurrence. Thus in sampling, say, two items from a batch of six, the possibilities are; (1,2), (1,3), (1,4), (1,5), (1,6), (2,3), 2,4), (2,5), (2,6), (3,4), (3,5), (3,6), (4,5), (4,6), (5,6).

There are also two ways in which each of these selections can occur (e.g. item 1 followed by item 2 or vice versa) but this order of selection is irrelevant. It is important, however, that all relevant selections should be possible, and simple random sampling is desirable. There are many quasi-random sampling methods which do not satisfy this requirement, and although they are sometimes used for their convenience, they may distort the operating characteristic.

An example of such quasi-random selection is that of systematic sampling. A random starting point is chosen, and every kth item is then selected in sequence. Thus for sampling 2 out of 6, we might, say, choose a random starting number in the range 1 - 3, and then take the next item but three. This would yield the possible selections (1,4), (2,5), and (3, 6), and although all items have the same chance of appearing in a sample, many sample configurations are excluded. If items 1 and 2 happened to be defective, under systematic sampling they could not both appear in the sample.

The subject of sampling lends itself to practical classroom work. For example, class members can prepare ‘batches’ of items which contain a few ‘defectives’ (pins, of which a few are deliberately bent, or even smarties or jelly babies of which some are chipped, cut in half, etc.). The merits of alternative sampling plans can be discussed, based on subjective impressions or on the calculation of some points on the Operating Characteristic. The schemes may then be tried out on the batches, using strict random sampling or quasi-random procedures. Some suggested sampling plans for batches of, say, 50 to 200 items of which 1% to 5% of items are defective are:
 
 
 
Sample size 13 20 32
Acceptance number 0 or l 0, l or 2 1, 2 or 3

(Plans from British Standard 6001:1972, which also gives details of the Operating Characteristics of these and many other plans).

Abergavenny

Back to top

Back to contents of The Best of Teaching Statistics
Back to main Teaching Statistics page