# \donttest{
N <- 100
X <- matrix(c(rnorm(N, 0, 1), rnorm(N, 3, 1)), ncol = 2, byrow = TRUE)
Y <- matrix(c(rnorm(N, 0, 1), rnorm(N, 3, 1)), ncol = 2, byrow = TRUE)
truth <- c(rep(1, N / 2), rep(2, N / 2))
data_modelled <- list(X, Y)
V <- length(data_modelled)
# MCMC parameters
R <- 5000
thin <- 50
burn <- 1000
K_max <- 10
K <- rep(K_max, V)
types <- rep("G", V)
n_chains <- 3
mcmc_out <- runMCMCChains(data_modelled, n_chains, R, thin, types, K = K)
predictFromMultipleChains(mcmc_out, burn)
# }
Run the code above in your browser using DataLab