empericalBAx: The empirical Bayesian approach for Beta-Binomial model given...

View source: R/612.Empirical_x.R

empericalBAxR Documentation

The empirical Bayesian approach for Beta-Binomial model given x

Description

The empirical Bayesian approach for Beta-Binomial model given x

Usage

empericalBAx(x, n, alp, sL, sU)

Arguments

x

- Number of successes

n

- Number of trials

alp

- Alpha value (significance level required)

sL

- Lower support for MLE stats::optimization

sU

- Upper support for MLE stats::optimization

Details

Highest Probability Density (HPD) and two tailed intervals are provided for the required x (any one value from 0, 1, 2 ..n) based on empirical Bayesian approach for Beta-Binomial model. Lower and Upper support values are needed to obtain the MLE of marginal likelihood for prior parameters.

Value

A dataframe with

x

- Number of successes (positive samples)

pomean

- Posterior mean

LEBAQ

- Lower limits of Quantile based intervals

UEBAQ

- Upper limits of Quantile based intervals

LEBAH

- Lower limits of HPD intervals

UEBAH

- Upper limits of HPD intervals

References

[1] 1998 Lehmann EL and Casella G Theory of Point Estimation, 2nd ed Springer, New York

See Also

Other Miscellaneous functions for Bayesian method: empericalBA(), probPOSx(), probPOS(), probPREx(), probPRE()

Examples

sL=runif(1,0,2)				#Lower and upper of Support for MLE stats::optimization
sU=runif(1,sL,10)
x=0; n= 5; alp=0.05
empericalBAx(x,n,alp,sL,sU)

RajeswaranV/proportion documentation built on June 17, 2022, 9:11 a.m.