diffprior | R Documentation |
Function for computing posterior probabilities based on the Snapshot Bayesian Hybrid Meta-Analysis Method or Snapshot Bayesian Meta-Analysis Method (uncorrected) for another than a uniform prior.
diffprior(prior, res.snap)
prior |
A vector of length four containing the prior probabilities for no, small, medium, and large true effect size. |
res.snap |
A data frame with posterior probabilities obtained with the
|
The function computes posterior probabilities for four true effect
sizes (no, small, medium, and large) based on the snapshot
or
uncor.snapshot
function for another than a uniform prior. For more
information see van Aert and van Assen (2016).
The diffprior
function returns a data frame with posterior probabilities
for no (p.0
), small (p.sm
), medium (p.me
), and large (p.la
)
true effect size.
Robbie C.M. van Aert R.C.M.vanAert@tilburguniversity.edu
van Aert, R.C.M. & van Assen, M.A.L.M. (2017). Bayesian evaluation of effect size after replicating an original study. PLoS ONE, 12(4), e0175302. doi:10.1371/journal.pone.0175302
### Example as presented on page 491 in Maxwell, Lau, and Howard (2015)
res.snap <- snapshot(ri=c(0.243, 0.114), ni=c(80, 172), alpha=.05)
### Prior probabilities with probablity for no effect twice as large as for the other true effects
prior <- c(0.4, 0.2, 0.2, 0.2)
### Compute posterior probabilities based on new prior
diffprior(prior = prior, res.snap = res.snap)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.