R/plot.comphat.R

plot.comphat <- function(x, ...){
  ci <- apply(x, 2, function(z) HPDinterval(as.mcmc(z), prob = 0.95))
  b <- barplot(apply(x, 2, mean), names.arg = 1:ncol(x), las = 1, ylim = c(0, max(c(ci))), col = "dark blue")
  segments(b, ci[1,], b, ci[2,], lwd = 5, col = "dark red")
  }

Try the ocomposition package in your browser

Any scripts or data that you put into this service are public.

ocomposition documentation built on May 2, 2019, 3:30 p.m.