ciCTWx: Continuity corrected Wald-T method of CI estimation

Description Usage Arguments Details Value References See Also Examples

View source: R/123.ConfidenceIntervals_CC_n_x.R

Description

Continuity corrected Wald-T method of CI estimation

Usage

1
ciCTWx(x, n, alp, c)

Arguments

x

- Number of successes

n

- Number of trials

alp

- Alpha value (significance level required)

c

- Continuity correction

Details

Approximate method based on a t_approximation of the standardized point estimator using the test statistic (abs(phat-p)-c)/SE where c > 0 is a constant for continuity correction for all x = 0, 1, 2 ..n. Boundary modifications when x = 0 or x = n using Wald adjustment method with h = 2.

Value

A dataframe with

x

Number of successes (positive samples)

LCTWx

T-Wald Lower limit

UCTWx

T-Wald Upper Limit

LABB

T-Wald Lower Abberation

UABB

T-Wald Upper Abberation

ZWI

Zero Width Interval

References

[1] 1998 Agresti A and Coull BA. Approximate is better than "Exact" for interval estimation of binomial proportions. The American Statistician: 52; 119 - 126.

[2] 1998 Newcombe RG. Two-sided confidence intervals for the single proportion: Comparison of seven methods. Statistics in Medicine: 17; 857 - 872.

[3] 2008 Pires, A.M., Amado, C. Interval Estimators for a Binomial Proportion: Comparison of Twenty Methods. REVSTAT - Statistical Journal, 6, 165-197.

See Also

prop.test and binom.test for equivalent base Stats R functionality, binom.confint provides similar functionality for 11 methods, wald2ci which provides multiple functions for CI calculation , binom.blaker.limits which calculates Blaker CI which is not covered here and propCI which provides similar functionality.

Other Continuity correction methods of CI estimation given x and n: PlotciCAllxg, PlotciCAllx, ciCAllx, ciCLTx, ciCSCx, ciCWDx

Examples

1
2
x=5; n=5; alp=0.05;c=1/2*n
ciCTWx(x,n,alp,c)

Example output

  x LCTWx UCTWx LABB UABB ZWI
1 5     0     1  YES  YES  NO

proportion documentation built on May 1, 2019, 7:54 p.m.