gMLE.pg {BayesGOF} | R Documentation |
Negative-Binomial Parameter Estimation
Description
Computes Type-II Maximum likelihood estimates \hat{\alpha}
and \hat{\beta}
for gamma prior g\sim
Gamma(\alpha, \beta)
.
Usage
gMLE.pg(cnt.vec, exposure = NULL, start.par = c(1,1))
Arguments
cnt.vec |
Vector containing Poisson counts. |
exposure |
Vector containing exposures for each count. The default is no exposure, thus |
start.par |
Initial values that will pass to |
Value
Returns a vector where the first component is \alpha
and the second component is the scale parameter \beta
for the gamma distribution: \frac{1}{\Gamma(\alpha)\beta^\alpha} \theta^{\alpha-1}e^{-\frac{\theta}{\beta}}.
Author(s)
Doug Fletcher
References
Koenker, R. and Gu, J., 2017. "REBayes: An R Package for Empirical Bayes Mixture Methods," Journal of Statistical Software, Articles, 82(8), pp. 1-26.
Examples
### without exposure
data(ChildIll)
ill.start <- gMLE.pg(ChildIll)
ill.start
### with exposure
data(NorbergIns)
X <- NorbergIns$deaths
E <- NorbergIns$exposure/344
norb.start <- gMLE.pg(X, exposure = E)
norb.start
[Package BayesGOF version 5.2 Index]