Empirical Highest Posterior Density Interval
Computes the Highest Posterior Density (HPD) interval from a posterior sample. Works only for scalar marginal posteriors.
hpd(x, prob = 0.95)
x
: a univariate or a posterior sample for a scalar parameter.prob
: posterior probability content.vector of two doubles.