Appendix B. Algorithms for Gibbs sampling for a growth model. A pdf file of this appendix is also available for viewing.

The joint posterior
distribution was determined by Gibbs sampling (Gelfand and
Smith 1990). A Gibbs sampler is a Markov chain Monte Carlo technique that
executes a random walk with a limiting distribution equal to the parameter distribution
of interest. Because random samples cannot be drawn directly from this complex
distribution, we factor the posterior into conditional distributions given here. We
used 10,000 iterations starting from different initial values. A ‘burn in’ of
500 steps was discarded. Ninety-five percent Bayesian credible intervals are
posterior quantiles. Propagation to the response *m* was determined using
quantiles of *m* drawn from the 9500 MCMC samples for all parameters.

*Regression
parameters*

The conditional posterior for regression parameters contains contributions from the likelihood and prior. For a single unknown variance (Eq. 7, Fig 1. Method 1) this density is

_{
}

Parameters are sampled directly
from _{ }
, where _{ }
, _{ } ,
and _{ }
. The conditional posterior for the variance was sampled from the inverse
gamma distribution

_{
}

_{
.}

For the traditional (ML) method,
the model prediction used for *s*^{2} and for the second *IG*
parameter is evaluated at _{
} .

For Method 2 (Eq. 8, Fig. 1),
we sample parameters from the bivariate normal with _{
} and _{
} . The covariance matrix
has plot specific variances along the diagonal. The *j*^{th}
variance has posterior conditional

_{
.}

For the
hierarchical model (Eq. 9, Fig. 1, Method 3) regression parameters come from
_{ } , where
_{ } , _{
} , _{
} , and _{
} . Hyperparameters are drawn from _{
} , where _{
} and _{
} . The parameter covariance matrix is drawn from the Wishart conditional
posterior

_{
}

(e.g., Gelman et al. 1995). Although regression parameters are given in matrix notation (for compactness), matrix inversions are too slow. All parameters are solved without resort to matrix inversion or (for the hierarchical model) loops over individuals.

*Half saturation
constant*

Parameter depends on the likelihood and on its prior Beta density. For Method 1, the conditional posterior is

_{
} _{ }

with appropriate modifications to the first distribution for different models. We used a Metropolis-Hastings step with a beta proposal density centered on the current value of .

*Latent (“true”)
light availabilities*

Light availability on plot *j*
enters the likelihood for the *n _{j}* seedlings on plot

_{
} _{ }
.

Sampling was executed with a Metropolis-Hastings step based on a Beta proposal density.

**Literature cited**

Gelfand,
A. E., and A. F. M. Smith. 1990. Sampling-based approaches to calculating
marginal densities. Journal of the American Statistical Association **85**:398–409.

Gelman, A., J. B. Carlin, H. S. Stern, and D. B. Rubin. 1995. Bayesian data analysis. Chapman and Hall, London, UK.