Learn R Programming

tolerance (version 3.0.0)

poistol.int: Poisson Tolerance Intervals

Description

Provides 1-sided or 2-sided tolerance intervals for Poisson random variables. From a statistical quality control perspective, these limits bound the number of occurrences (which follow a Poisson distribution) in a specified future time period.

Usage

poistol.int(x, n, m = NULL, alpha = 0.05, P = 0.99, side = 1, 
            method = c("TAB", "LS", "SC", "CC", "VS", "RVS",
            "FT", "CSC"))

Value

poistol.int returns a data frame with items:

alpha

The specified significance level.

P

The proportion of occurrences in future time periods of length m.

lambda.hat

The mean occurrence rate per unit time, calculated by x/n.

1-sided.lower

The 1-sided lower tolerance bound. This is given only if side = 1.

1-sided.upper

The 1-sided upper tolerance bound. This is given only if side = 1.

2-sided.lower

The 2-sided lower tolerance bound. This is given only if side = 2.

2-sided.upper

The 2-sided upper tolerance bound. This is given only if side = 2.

Arguments

x

The number of occurrences of the event in time period n. Can be a vector of length n, in which case the sum of x is used.

n

The time period of the original measurements.

m

The specified future length of time. If m = NULL, then the tolerance limits will be constructed assuming n for the future length of time.

alpha

The level chosen such that 1-alpha is the confidence level.

P

The proportion of occurrences in future time lengths of size m to be covered by this tolerance interval.

side

Whether a 1-sided or 2-sided tolerance interval is required (determined by side = 1 or side = 2, respectively).

method

The method for calculating the lower and upper confidence bounds, which are used in the calculation of the tolerance bounds. The default method is "TAB", which is the tabular method and is usually preferred for a smaller number of occurrences. "LS" gives the large-sample (Wald) method, which is usually preferred when the number of occurrences is x>20. "SC" gives the score method, which again is usually used when the number of occurrences is relatively large. "CC" gives a continuity-corrected version of the large-sample method. "VS" gives a variance-stabilized version of the large-sample method. "RVS" is a recentered version of the variance-stabilization method. "FT" is the Freeman-Tukey method. "CSC" is the continuity-corrected version of the score method. More information on these methods can be found in the "References".

References

Barker, L. (2002), A Comparison of Nine Confidence Intervals for a Poisson Parameter When the Expected Number of Events Is \(\le 5\), The American Statistician, 56, 85--89.

Freeman, M. F. and Tukey, J. W. (1950), Transformations Related to the Angular and the Square Root, Annals of Mathematical Statistics, 21, 607--611.

Hahn, G. J. and Chandra, R. (1981), Tolerance Intervals for Poisson and Binomial Variables, Journal of Quality Technology, 13, 100--110.

See Also

Poisson, umatol.int

Examples

Run this code
## 95%/90% 1-sided Poisson tolerance limits for future 
## occurrences in a period of length 3.  All seven methods
## are presented for comparison.

poistol.int(x = 45, n = 9, m = 3, alpha = 0.05, P = 0.90,
            side = 1, method = "TAB")
poistol.int(x = 45, n = 9, m = 3, alpha = 0.05, P = 0.90,
            side = 1, method = "LS")
poistol.int(x = 45, n = 9, m = 3, alpha = 0.05, P = 0.90,
            side = 1, method = "SC")
poistol.int(x = 45, n = 9, m = 3, alpha = 0.05, P = 0.90,
            side = 1, method = "CC")
poistol.int(x = 45, n = 9, m = 3, alpha = 0.05, P = 0.90,
            side = 1, method = "VS")
poistol.int(x = 45, n = 9, m = 3, alpha = 0.05, P = 0.90,
            side = 1, method = "RVS")
poistol.int(x = 45, n = 9, m = 3, alpha = 0.05, P = 0.90,
            side = 1, method = "FT")
poistol.int(x = 45, n = 9, m = 3, alpha = 0.05, P = 0.90,
            side = 1, method = "CSC")
            
## 95%/90% 2-sided Poisson tolerance intervals for future 
## occurrences in a period of length 15.  All seven methods
## are presented for comparison.

poistol.int(x = 45, n = 9, m = 15, alpha = 0.05, P = 0.90,
            side = 2, method = "TAB")
poistol.int(x = 45, n = 9, m = 15, alpha = 0.05, P = 0.90,
            side = 2, method = "LS")
poistol.int(x = 45, n = 9, m = 15, alpha = 0.05, P = 0.90,
            side = 2, method = "SC")
poistol.int(x = 45, n = 9, m = 15, alpha = 0.05, P = 0.90,
            side = 2, method = "CC")
poistol.int(x = 45, n = 9, m = 15, alpha = 0.05, P = 0.90,
            side = 2, method = "VS")
poistol.int(x = 45, n = 9, m = 15, alpha = 0.05, P = 0.90,
            side = 2, method = "RVS")
poistol.int(x = 45, n = 9, m = 15, alpha = 0.05, P = 0.90,
            side = 2, method = "FT")
poistol.int(x = 45, n = 9, m = 15, alpha = 0.05, P = 0.90,
            side = 2, method = "CSC")

Run the code above in your browser using DataLab