Calculation of a contour probability (possible Bayesian counterpart of a p-value) based on the MCMC posterior sample for a univariate parameter corresponding to the equal-tail credible interval.
For details, see Bogaerts, Komárek and Lesaffre (201X, Sec. 9.1.4.2).
contourProb(sample, theta0 =0)
Arguments
sample: a numeric vector with the MCMC sample from the posterior distribution of a univariate parameter.
theta0: a value of the parameter to which the contour probability is to be related.
Returns
A value of the contour probability.
References
Bogaerts, K., Komárek, A. and Lesaffre, E. (201X). Survival Analysis with Interval-Censored Data: A Practical Approach. Boca Raton: Chapman and Hall/CRC.