Fit the hidden Potts model using a Markov chain Monte Carlo algorithm.
mcmcPotts(
y,
neighbors,
blocks,
priors,
mh,
niter = 55000,
nburn = 5000,
truth = NULL
)
A matrix containing MCMC samples for the parameters of the Potts model.
A vector of observed pixel data.
A matrix of all neighbors in the lattice, one row per pixel.
A list of pixel indices, dividing the lattice into independent blocks.
A list of priors for the parameters of the model.
A list of options for the Metropolis-Hastings algorithm.
The number of iterations of the algorithm to perform.
The number of iterations to discard as burn-in.
A matrix containing the ground truth for the pixel labels.