asymcnfB | R Documentation |
asymcnfB
obtains asymmetric bayesian confidence bands on a target function
asymcnfB(DF, DFmat, alpha = 0.05, scale = FALSE)
DF |
the target distribution/quantile function as a vector |
DFmat |
the matrix of draws of the distribution, rows correspond to
elements in |
alpha |
level such that |
scale |
logical for scaling using the inter-quartile range |
a list containing
cmin - constant to subtract from DF
for the lower confidence band
cmax - constant to add to DF
for the upper confidence band
set.seed(14); m=matrix(rbeta(500,1,4),nrow = 5) + 1:5
DF = apply(m,1,mean); plot(1:5,DF,type="l",ylim = c(min(m),max(m)), xlab = "Index")
asyCB<- asymcnfB(DF,DFmat = m)
lines(1:5,DF-asyCB$cmin,lty=2); lines(1:5,DF+asyCB$cmax,lty=2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.