DS.micro.inf {BayesGOF} | R Documentation |
Provides DS nonparametric adaptive Bayes and parametric estimate for a specific observation y_0.
DS.micro.inf(DS.GF.obj, y.0, n.0, e.0 = NULL)
DS.GF.obj |
Object resulting from running DS.prior function on a data set. |
y.0 |
For Binomial family, number of success y_i for new study. In the Poisson family, it is the number of counts. Represents the study mean for the Normal family. |
n.0 |
For the Binomial family, the total number of trials for the new study. In the Normal family, |
e.0 |
In the case of the Poisson family with exposure, represents the exposure value for a given count value |
Returns an object of class DS.GF.micro
that can be used in conjunction with plot command to display the DS posterior distribution for the new study.
DS.mean |
Posterior mean for π_{LP}(θ | y_0). |
DS.mode |
Posterior mode for π_{LP}(θ | y_0). |
PEB.mean |
Posterior mean for π_G(θ | y_0). |
PEB.mode |
Posterior mode for π_G(θ | y_0). |
post.vec |
Vector containing |
study |
User-provided y_0 and n_0. |
post.fit |
Dataframe with θ, π_G(θ | y_0), and π_{LP}(θ | y_0). |
Doug Fletcher, Subhadeep Mukhopadhyay
Mukhopadhyay, S. and Fletcher, D., 2018. "Generalized Empirical Bayes via Frequentist Goodness of Fit," Nature Scientific Reports, 8(1), p.9983, https://www.nature.com/articles/s41598-018-28130-5.
### MicroInference for Naval Shipyard Data: sample where y = 0 and n = 5 data(ship) ship.ds <- DS.prior(ship, max.m = 2, c(.5,.5), family = "Binomial") ship.ds.micro <- DS.micro.inf(ship.ds, y.0 = 0, n.0 = 5) ship.ds.micro plot(ship.ds.micro)