% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/diagnostics.R
\name{hpd_interval}
\alias{hpd_interval}
\title{Highest Posterior Density (HPD) Interval Calculation}
\usage{
hpd_interval(x, prob = 0.95)
}
\arguments{
\item{x}{Numeric vector of sample draws.}

\item{prob}{Credibility level (1 - significance level). Default is 0.95.}
}
\value{
A named numeric vector of length 2 containing \code{lower} and \code{upper} bounds.
}
\description{
Computes the Highest Posterior Density (HPD) interval for MCMC posterior samples
at specified confidence / significance levels (e.g., 90\%, 95\%, 99\%).
}
\examples{
samples <- rnorm(1000, mean = 5, sd = 1)
hpd_interval(samples, prob = 0.95)
}
