Title: | Acceptance Sampling Ideas Originated by H.F. Dodge |
---|---|
Description: | A variety of sampling plans are able to be compared using evaluations of their operating characteristics (OC), average outgoing quality (OQ), average total inspection (ATI) etc. |
Authors: | A. Jonathan R. Godfrey [aut, cre], K. Govindaraju [aut] |
Maintainer: | A. Jonathan R. Godfrey <[email protected]> |
License: | GPL |
Version: | 0.9-4 |
Built: | 2024-11-08 02:42:17 UTC |
Source: | https://github.com/ajrgodfrey/dodge |
A number of sampling plans can be compared for their operating characteristics and other commonly used functions.
Package: | Dodge |
Type: | Package |
Version: | 0.9-4 |
Date: | 2020-12-13 |
License: | GPL |
LazyLoad: | yes |
Raj Govindaraju and Jonathan Godfrey
Maintainer: A. Jonathan R. Godfrey <[email protected]>
Dodge
Chain Sampling Plans for the binomial and Poisson distributions.
ChainBinomial(N, n, i, p = seq(0, 0.2, 0.001), Plots = TRUE)
ChainBinomial(N, n, i, p = seq(0, 0.2, 0.001), Plots = TRUE)
N |
the lot size |
n |
the sample size |
i |
the number of preceding lots that are free from nonconforming units for the lot to be accepted |
p |
a vector of values for the possible fraction of product that is nonconforming |
Plots |
logical to request generation of the four plots |
A matrix containing the argument p
as supplied and the
calculated OC, ATI and ???
Raj Govindaraju with minor editing by Jonathan Godfrey
Dodge, H.F. (1955) “Chain Sampling Inspection Plan”, Industrial Quality Control 11(4), pp10-13.
require(Dodge) ChainBinomial(1000, 20,3) ChainPoisson(1000, 20,3)
require(Dodge) ChainBinomial(1000, 20,3) ChainPoisson(1000, 20,3)
Computes the average sample number for a curtailed inspection plan for single sampling plans. Functionality is currently available for only the binomial distribution.
CurtBinomial(n, Ac, p = seq(0, 0.5, 0.01), Plots = TRUE)
CurtBinomial(n, Ac, p = seq(0, 0.5, 0.01), Plots = TRUE)
n |
the sample size (potential) |
Ac |
the acceptance number |
p |
a vector of values for the possible fraction of product that is nonconforming |
Plots |
logical to request generation of the four plots |
Raj Govindaraju with minor editing by Jonathan Godfrey
CurtBinomial(20,1)
CurtBinomial(20,1)
Double Sampling Plans for the binomial and Poisson distributions.
DSPlanBinomial(N, n1, n2, Ac1, Re1, Ac2, p = seq(0, 0.25, 0.005), Plots = TRUE)
DSPlanBinomial(N, n1, n2, Ac1, Re1, Ac2, p = seq(0, 0.25, 0.005), Plots = TRUE)
N |
the lot size |
n1 |
the sample size in the first stage of the plan |
n2 |
the sample size in the second stage of the plan |
Ac1 |
the first stage acceptance number |
Re1 |
the first stage rejection number |
Ac2 |
the second stage acceptance number |
p |
a vector of values for the possible fraction of product that is nonconforming |
Plots |
logical to request generation of the four plots |
Raj Govindaraju with minor editing by Jonathan Godfrey
Dodge, H.F. and Romig, H.G. (1959) “Sampling Inspection Tables, Single and Double Sampling”, Second edition, John Wiley and Sons, New York.
DSPlanBinomial(1000, 10, 10, 0, 2, 1) DSPlanPoisson(1000, 10, 10, 0,2, 1)
DSPlanBinomial(1000, 10, 10, 0, 2, 1) DSPlanPoisson(1000, 10, 10, 0,2, 1)
The lot sensitive compliance sampling plans for given parameters.
LSP(N, LTPD, beta, p = seq(0, 0.3, 0.001), Plots = TRUE)
LSP(N, LTPD, beta, p = seq(0, 0.3, 0.001), Plots = TRUE)
N |
the lot size |
LTPD |
the lot tolerance percent defective, also known as the limiting quality |
beta |
consumer risk |
p |
fraction nonconforming |
Plots |
logical indicating if the four plots are required |
Raj Govindaraju with minor editing by Jonathan Godfrey
Schilling, E.G. (1978) “A Lot Sensitive Sampling Plan for Compliance Testing and Acceptance Inspection”, Journal of Quality Technology 10(2), pp47-51.
LSP(1000, 0.04,0.05)
LSP(1000, 0.04,0.05)
Creates plots for analysing the design of an acceptance sampling procedure.
## S3 method for class 'AccSampPlan' plot(x, y = NULL, ...)
## S3 method for class 'AccSampPlan' plot(x, y = NULL, ...)
x |
an object of class AccSampPlan, CurtSampPlan, or SeqSampPlan |
y |
ignored |
... |
further arguments passed to or from other methods. |
At this stage the plot.AccSampPlan
method only plots the Operating
Characteristic (OC) curve, the Average (AOQ) and (ATI) against the
proportion (p) of product that is nonconforming. It also plots the curtailed
sample size or the average sample number (ASN) against p. Further
development is still required.
Jonathan Godfrey with some assistance from Raj Govindaraju
Plan1 = SSPlanBinomial(1000, 20,1, Plots=FALSE) plot(Plan1)
Plan1 = SSPlanBinomial(1000, 20,1, Plots=FALSE) plot(Plan1)
Adds to the base functionality for the print() command. The accompanying
plot
methods are more sophisticated.
## S3 method for class 'AccSampPlan' print(x, ...)
## S3 method for class 'AccSampPlan' print(x, ...)
x |
an object of class AccSampPlan, CurtSampPlan, or SeqSampPlan |
... |
further arguments passed to or from other methods. |
These methods print the most necessary elements of the corresponding objects.
Jonathan Godfrey
The corresponding plot method is far more interesting. See
plot.AccSampPlan
for example.
Selects the appropriate sequential sampling plan from the given inputs. The only distribution that has been used in functions thus far is the binomial, but further development is expected.
SeqDesignBinomial(N = NULL, AQL, alpha, LQL, beta, Plots = TRUE)
SeqDesignBinomial(N = NULL, AQL, alpha, LQL, beta, Plots = TRUE)
N |
the lot size, ignored for the design of the plan unless the underlying distribution is hypergeometric |
AQL |
Acceptable quality level |
alpha |
producer's risk |
LQL |
Limiting quality level |
beta |
consumers' risk |
Plots |
logical stating if the sequential chart should be plotted |
Raj Govindaraju and Jonathan Godfrey
Designs an attribute sequential sampling plan for given AQL, alpha, LQL, and beta. The user can request plots describing the performance of the plan.
SequentialBinomial(x, Plots = TRUE)
SequentialBinomial(x, Plots = TRUE)
x |
an object of class SeqSampPlan, or at least having the same elements as one. |
Plots |
logical indicating if the four plots should be returned |
Raj Govindaraju with minor editing by Jonathan Godfrey
PlanDesign=SeqDesignBinomial(AQL=0.01, alpha=0.05, LQL=0.04, beta=0.05, Plots=FALSE) SequentialBinomial(PlanDesign)
PlanDesign=SeqDesignBinomial(AQL=0.01, alpha=0.05, LQL=0.04, beta=0.05, Plots=FALSE) SequentialBinomial(PlanDesign)
Design a single sampling plan for given AQL, alpha, LQL, and beta. Currently there are functions for the binomial and Poisson distributions.
SSPDesignBinomial(AQL, alpha, LQL, beta)
SSPDesignBinomial(AQL, alpha, LQL, beta)
AQL |
Acceptable quality level |
alpha |
producer's risk |
LQL |
Limiting quality level |
beta |
consumers' risk |
Raj Govindaraju with minor editing by Jonathan Godfrey
Dodge, H.F. and Romig, H.G. (1959) “Sampling Inspection Tables, Single and Double Sampling”, Second edition, John Wiley and Sons, New York.
SSPDesignBinomial(0.01, 0.05, 0.04, 0.05) SSPDesignPoisson(0.01, 0.05, 0.04, 0.05)
SSPDesignBinomial(0.01, 0.05, 0.04, 0.05) SSPDesignPoisson(0.01, 0.05, 0.04, 0.05)
Single sampling plans for the binomial, hypergeometric and Poisson distributions.
SSPlanBinomial(N, n, Ac, p = seq(0, 0.3, 0.001), Plots = TRUE)
SSPlanBinomial(N, n, Ac, p = seq(0, 0.3, 0.001), Plots = TRUE)
N |
the lot size |
n |
the sample size |
Ac |
the acceptance number, being the maximum allowable number of non-conforming units or non-conformities |
p |
a vector of values for the possible fraction of product that is non-conforming |
Plots |
logical to request generation of the four plots |
Raj Govindaraju with minor editing by Jonathan Godfrey
Dodge, H.F. and Romig, H.G. (1959) “Sampling Inspection Tables, Single and Double Sampling”, Second edition, John Wiley and Sons, New York.
SSPlanBinomial(1000, 20,1) SSPlanHyper(5000, 200,3) SSPlanPoisson(1000, 20,1)
SSPlanBinomial(1000, 20,1) SSPlanHyper(5000, 200,3) SSPlanPoisson(1000, 20,1)
Design the variable sampling plan for given AQL, alpha, LQL, and beta.
VSPDesign(AQL, alpha, LQL, beta)
VSPDesign(AQL, alpha, LQL, beta)
AQL |
Acceptable quality level |
alpha |
producer's risk |
LQL |
Limiting quality level |
beta |
consumers' risk |
Raj Govindaraju with minor editing by Jonathan Godfrey
VSPDesign(AQL=0.01, alpha=0.05, LQL=0.04, beta=0.05)
VSPDesign(AQL=0.01, alpha=0.05, LQL=0.04, beta=0.05)
Variable sampling plans for known and unknown sigma, evaluated for given parameters.
VSPKnown(N, n, k, Pa = seq(0, 1, 0.001), Plots = TRUE)
VSPKnown(N, n, k, Pa = seq(0, 1, 0.001), Plots = TRUE)
N |
the lot size |
n |
the sample size |
k |
the acceptability constant |
Pa |
fraction nonconforming |
Plots |
logical indicating whether the four plots are required |
Raj Govindaraju with minor editing by Jonathan Godfrey
VSPKnown(1000, 20,1) VSPUnknown(1000, 20,1)
VSPKnown(1000, 20,1) VSPUnknown(1000, 20,1)