View source: R/Proxytools_helpers.R
calculate_ci | R Documentation |
Calculate credible intervals for samples (e.g. output from Monte Carlo or Markov Chain Monte Carlo methods)
calculate_ci(samples, level, simple = TRUE)
samples |
Vector of samples |
level |
Credible level |
simple |
If TRUE computation through quantiles, otherwise smallest interval containing the respective probability mass is computed |
Vector with upper and lower credible interval
testsamples <- rnorm(1000,0,1)
level <- 0.95
simple <- TRUE
testci <- calculate_ci(testsamples, level,simple)
print(testci)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.