Computes the posterior distribution of the
parameters in a random-effects meta-analysis (expressed
as a normal-normal hierarchical model) for
each of five benchmark heterogeneity priors and
the actual heterogeneity prior(s) specified.
Applies the function bayesmeta from the package bayesmeta.
fit_models_RA_5bm(df, tau.prior=list(), compute.J.bm=TRUE,
m_J=NA, M_J=NA, upper.J=3, digits.J=2,
m_inf=NA, M_inf=NA, rlmc0=0.0001, rlmc1=0.9999,
mu.mean=0, mu.sd=4)A list with two elements:
The first element named "fits" is a list containing the model fits and the
second element called "par" is a named vector giving the parameter values
of the benchmark priors.
The vector "par" has the following five components:
m_inf, M_J, m_J, M_inf and C.
The element "fits" is a list of lists of class bayesmeta.
This list has length \(5\) + length(tau.prior)
and contains one element for each heterogeneity prior considered
(5 benchmark priors and the actual priors specified),
in the following order:
for SGC(m_inf) benchmark prior
for SIGC(M_J) benchmark prior
for SGC(m_J) benchmark prior
for SIGC(M_inf) benchmark prior
for Jeffreys (improper) reference prior
for the first prior in the list tau.prior (if specified)
for the second prior in the list tau.prior (if specified)
...
for the nth prior in the list tau.prior (if specified)
See bayesmeta in the package bayesmeta
for information on the structure of the lists of class bayesmeta.
data frame with one column "y" containing the (transformed) effect estimates for the individual studies and one column "sigma" containing the standard errors of these estimates.
list of prior specifications, which are either functions returning the probability densities of the actual priors of interest for the heterogeneity parameter tau or character strings specifying priors implemented in the bayesmeta function. See the documentation of the argument tau.prior of the bayesmeta function for details.
logical. Specifies if the parameter values of the two benchmarks priors
SGC(\(m_J\)) and SIGC(\(M_J\)) and the corresponding marginal posteriors should be computed.
Defaults to TRUE.
parameter value \(m=m_J\) of the SGC(\(m\)) prior,
which induces a marignal posterior for the heterogeneity standard deviation tau close to Jeffreys reference posterior (wrt the Hellinger distance).
If set to NA (the default), this parameter is computed
using the function m_j_sgc and the arguments
df, upper.J, digits.J, mu.mean and mu.sd.
parameter value \(M=M_J\) of the SIGC(\(M\)) prior,
which induces a marignal posterior for the heterogeneity standard deviation tau close to Jeffreys reference posterior (wrt the Hellinger distance).
If set to NA (the default), this parameter is computed
using the function M_j_sigc and the arguments
df, upper.J, digits.J, mu.mean and mu.sd.
upper bound for the parameters M_J and m_J. Real number in \((1,\infty)\). Is required only if M_J=NA or m_J=NA.
specifies the desired precision of the parameter values \(M_J\) and \(m_J\), i.e. to how many digits these two values
should be determined. Possible values are 1,2,3. Defaults to 2.
Is required only if M_J=NA or m_J=NA.
parameter value \(m=m_{inf}\) of the SGC(\(m\)) prior,
such that the median relative latent model complexity (RLMC) is close to 0.
If set to NA (the default), this parameter is computed
using the function m_inf_sgc, such that the median RLMC is
approximately equal to rlmc0.
parameter value \(M=M_{inf}\) of the SIGC(\(M\)) prior,
such that the median relative latent model complexity (RLMC) is close to 1.
If set to NA (the default), this parameter is computed
using the function M_inf_sigc, such that the median RLMC is
approximately equal to rlmc1.
RLMC target value for the SGC(\(m_{inf}\)) benchmark prior (typically close to 0).
Is required only if m_inf=NA.
RLMC target value for the SIGC(\(M_{inf}\)) benchmark prior (typically close to 1).
Is required only if M_inf=NA.
mean of the normal prior for the effect mu.
standard deviation of the normal prior for the effect mu.
This function may take several minutes to run if the parameter m_J and/or M_J
is not specified,
especially if the desired precision is digits.J=2 or even digits.J=3.
If fit_models_RA ends with an error or warning,
we recommend to check the values of the parameters M_J, m_J and M_inf
for the benchmark priors.
The choice of these parameters can be studied by using the functions
M_j_sigc, m_j_sgc and M_inf_sigc.
If one of the parameters m_inf, M_J, m_J or M_inf
has a value larger than 5*10^6, a warning message will be displayed,
since such large parameter values may lead to numerical problems
in the bayesmeta function.
The five heterogeneity benchmark priors used are introduced in the Supplementary Material of Ott et al. (2021, Sections 2.2.1, 2.5 and 2.6, see also Section 3.4 of Ott et al. (2021) for Jeffreys reference prior), where they are denoted by SGC(\(m_{inf}\)), SIGC(\(M_J\)), SGC(\(m_J\)), SIGC(\(M_{inf}\)) and Jeffreys. Note that "Jeffreys" refers to Jeffreys reference prior, which is improper, but leads to a proper posterior if there are at least two studies in the meta-analysis data set.
If the fits induced by the SIGC(\(M_J\)) and SGC(\(m_J\)) benchmarks
are not needed for the analysis (such as for the posterior reference analysis
proposed in the Supplementary Material of Ott et al. (2021), see for example Table 8 for illustration),
specifying
compute.J.bm=FALSE may reduce the
computation time by several minutes.
The default values for mu.mean and mu.sd
are suitable for effects mu on the log odds (ratio) scale.
Ott, M., Plummer, M., Roos, M. (2021). Supplementary Material: How vague is vague? How informative is informative? Reference analysis for Bayesian meta-analysis. Statistics in Medicine. tools:::Rd_expr_doi("10.1002/sim.9076")
Ott, M., Plummer, M., Roos, M. (2021). How vague is vague? How informative is informative? Reference analysis for Bayesian meta-analysis. Statistics in Medicine 40, 4505--4521. tools:::Rd_expr_doi("10.1002/sim.9076")
bayesmeta in the package bayesmeta,
m_j_sgc, M_j_sigc,
m_inf_sgc, M_inf_sigc
# for aurigular acupuncture (AA) data set with one
# actual half-normal and the "DuMouchel" heterogeneity prior
data(aa)
# warning: it takes ca. 7 min. to run this function
fit_models_RA_5bm(df=aa, tau.prior=list(function(t)dhalfnormal(t, scale=1),
"DuMouchel"))
# computation is much faster if m_J and M_J are specified
fit_models_RA_5bm(df=aa, tau.prior=list(function(t)dhalfnormal(t, scale=1),
"DuMouchel"),
m_J = 1.35, M_J = 1.3)
Run the code above in your browser using DataLab