Description Usage Arguments Details Value References See Also Examples
View source: R/641.PosteriorProbs.R
Bayesian posterior Probabilities
1 | probPOS(n, a, b, th)
|
n |
- Number of trials |
a |
- Prior Parameters |
b |
- Prior Parameters |
th |
- Theta value seeking Pr(Theta/X < th) |
Computes probability of the event p < p0 (p0 is specified in [0, 1]) based
on posterior distribution of Beta-Binomial model with given parameters for prior Beta
distribution for all x = 0, 1, 2......n where n
is the number of trials
A dataframe with
x |
Number of successes |
PosProb |
Posterior probability |
[1] 2002 Gelman A, Carlin JB, Stern HS and Dunson DB Bayesian Data Analysis, Chapman & Hall/CRC [2] 2006 Ghosh M, Delampady M and Samanta T. An introduction to Bayesian analysis: Theory and Methods. Springer, New York
Other Miscellaneous functions for Bayesian method: empericalBAx
,
empericalBA
, probPOSx
,
probPREx
, probPRE
1 2 | n=5; a=0.5; b=0.5; th=0.5;
probPOS(n,a,b,th)
|
x PosProb
1 0 0.993127696
2 1 0.912287200
3 2 0.669765259
4 3 0.330234727
5 4 0.087712909
6 5 0.006872303
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.