Learn R Programming

LBI (version 0.2.2)

LIbin: Likelihood Interval for a Proportion or a Binomial Distribution

Description

Likelihood interval of a proportion in one group

Usage

LIbin(y, n, k, conf.level=0.95, eps=1e-8)

Value

y

positive (concerning) event count

n

total trial count

PE

maximum likelihood estimate on the proportion

LL

lower limit of likelihood interval

UL

upper limit of likelihood interval

Arguments

y

positive event count of a group

n

total count of a group

k

1/k likelihood interval will be calculated

conf.level

approximately corresponding confidence level. If k is specified, this is ignored.

eps

Values less than eps are considered as 0.

Author

Kyun-Seop Bae k@acr.kr

Details

It calculates likelihood interval of a proportion in one group. The likelihood interval is asymmetric and there is no standard error in the output. If you need percent scale, multiply the output by 100.

References

Fisher RA. Statistical methods and scientific inference. 3e. 1973. pp68-76.

See Also

binom.test, prop.test

Examples

Run this code
  LIbin(3, 14, k=2)
  LIbin(3, 14, k=5)
  LIbin(3, 14, k=15)
  LIbin(3, 14)
# binom.test(3, 14)
# prop.test(3, 14) 

Run the code above in your browser using DataLab