probPREx: The Predicted probability - Bayesian approach

Description Usage Arguments Details Value References See Also Examples

View source: R/622.Poster_Predictive_x.R

Description

The Predicted probability - Bayesian approach

Usage

1
probPREx(x, n, xnew, m, a1, a2)

Arguments

x

- Number of successes

n

- Number of trials from data

xnew

- Required size of number of success

m

- Future :Number of trials

a1

- Beta Prior Parameters for Bayesian estimation

a2

- Beta Prior Parameters for Bayesian estimation

Details

Computes posterior predictive probability for the required size of number of successes for xnew of m trials from the given number of successes x of n trials for the given parameters for Beta prior distribution

Value

A dataframe with x,n,xnew,m,preprb

x

Number of successes

n

Number of trials

xnew

Required size of number of success

m

Future - success, trails

preprb

The predicted probability

References

[1] 2002 Gelman A, Carlin JB, Stern HS and Dunson DB Bayesian Data Analysis, Chapman & Hall/CRC

See Also

Other Miscellaneous functions for Bayesian method: empericalBAx, empericalBA, probPOSx, probPOS, probPRE

Examples

1
2
x=0; n=1; xnew=10; m=10; a1=1; a2=1
probPREx(x,n,xnew,m,a1,a2)

proportion documentation built on May 1, 2019, 7:54 p.m.