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 |
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 |
DS.mode |
Posterior mode for |
PEB.mean |
Posterior mean for |
PEB.mode |
Posterior mode for |
post.vec |
Vector containing |
study |
User-provided |
post.fit |
Dataframe with |
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)