extract_ci {HuraultMisc} | R Documentation |
Extract confidence intervals from a vector of samples
Description
Extract confidence intervals from a vector of samples
Usage
extract_ci(x, CI_level = seq(0.1, 0.9, 0.1), type = c("eti", "hdi"))
Arguments
x |
Vector of samples from a distribution. |
CI_level |
Vector containing the level of the confidence/credible intervals. |
type |
"eti" for equal-tailed intervals and "hdi" for highest density intervals. |
Value
Dataframe with columns: Lower
, Upper
, Level.
Examples
x <- rexp(1e4)
extract_ci(x, type = "eti")
extract_ci(x, type = "hdi")
[Package HuraultMisc version 1.1.1 Index]