View source: R/ui_predictions.R
tidy_mcmc | R Documentation |
Extract a tidy output from an mcmc.list
tidy_mcmc(x, spread = FALSE, include_constant = TRUE)
x |
An mcmc.list object |
spread |
Boolean, spread the parameters into separate columns? |
include_constant |
Boolean, include constant parameters as proper parameter traces? |
A tidy table containing one iteration per row
fit <- lapply(1:4, function(i) {
z <- matrix(rnorm(200), ncol = 2)
colnames(z) <- c("alpha", "beta")
coda::as.mcmc(z)
})
fit <- coda::as.mcmc.list(fit)
tidy_mcmc(fit)
tidy_mcmc(fit, spread = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.