powered by
Implements Gibbs sampling for estimating a two-way table of means under a hierarchical regression model.
hiergibbs(data,m)
matrix of simulated values of regression vector
matrix of simulated values of cell means
vector of simulated values of second-stage prior variance
data matrix with columns observed sample means, sample sizes, and values of two covariates
number of cycles of Gibbs sampling
Jim Albert
data(iowagpa) m=1000 s=hiergibbs(iowagpa,m)
Run the code above in your browser using DataLab