meta_random | R Documentation |
Bayesian meta-analysis assuming that the effect size d
varies across
studies with standard deviation \tau
(i.e., a random-effects model).
meta_random(
y,
SE,
labels,
data,
d = prior("cauchy", c(location = 0, scale = 0.707)),
tau = prior("invgamma", c(shape = 1, scale = 0.15)),
rscale_contin = 0.5,
rscale_discrete = 0.707,
centering = TRUE,
logml = "integrate",
summarize = "stan",
ci = 0.95,
rel.tol = .Machine$double.eps^0.3,
logml_iter = 5000,
silent_stan = TRUE,
...
)
y |
effect size per study. Can be provided as (1) a numeric vector, (2)
the quoted or unquoted name of the variable in |
SE |
standard error of effect size for each study. Can be a numeric
vector or the quoted or unquoted name of the variable in |
labels |
optional: character values with study labels. Can be a
character vector or the quoted or unquoted name of the variable in
|
data |
data frame containing the variables for effect size |
d |
|
tau |
|
rscale_contin |
scale parameter of the JZS prior for the continuous covariates. |
rscale_discrete |
scale parameter of the JZS prior for discrete moderators. |
centering |
whether continuous moderators are centered. |
logml |
how to estimate the log-marginal likelihood: either by numerical
integration ( |
summarize |
how to estimate parameter summaries (mean, median, SD,
etc.): Either by numerical integration ( |
ci |
probability for the credibility/highest-density intervals. |
rel.tol |
relative tolerance used for numerical integration using
|
logml_iter |
number of iterations (per chain) from the posterior
distribution of |
silent_stan |
whether to suppress the Stan progress bar. |
... |
further arguments passed to |
### Bayesian Random-Effects Meta-Analysis (H1: d>0)
data(towels)
set.seed(123)
mr <- meta_random(logOR, SE, study,
data = towels,
d = prior("norm", c(mean = 0, sd = .3), lower = 0),
tau = prior("invgamma", c(shape = 1, scale = 0.15))
)
mr
plot_posterior(mr)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.