Gibbs sampler for one-way ANOVA
Value
a list of posterior samples for group means, grand mean, variance within, and variance between
Details
Assumes Normal likelihood, Normal and log Uniform priors, Normal and log Uniform hyperpriors
Examples
if (FALSE) { # \dontrun{
set.seed(1234)
# Starling weight data
y = data.frame(obs = c(78, 88, 87, 88, 83, 82, 81, 80, 80, 89,
78, 78, 83, 81, 78, 81, 81, 82, 76, 76,
79, 73, 79, 75, 77, 78, 80, 78, 83, 84,
77, 69, 75, 70, 74, 83, 80, 75, 76, 75),
group = c(1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
4, 4, 4, 4, 4, 4, 4, 4, 4, 4))
mcmc = gibbs_anova(y, 10000, 5000)
} # }