settings.meta: Print and change default settings to conduct and print or...

View source: R/settings.meta.R

settings.metaR Documentation

Print and change default settings to conduct and print or plot meta-analyses in R package meta.

Description

Print and change default settings to conduct and print or plot meta-analyses in R package meta. The following general settings are available: Review Manager 5, Journal of the American Medical Association.

Usage

settings.meta(..., quietly = TRUE)

Arguments

...

Arguments to change default settings.

quietly

A logical indicating whether information on settings should be printed.

Details

This function can be used to define defaults for several arguments (i.e., assignments using gs) of the following R functions: metabin, metacont, metacor, metacr, metagen, metainc, metaprop, metarate

Furthermore, some of these settings are considered to print meta-analysis results and to produce forest plots.

The function can be used to either change individual settings (see Examples) or use one of the following general settings:

  • settings.meta("RevMan5")

  • settings.meta("JAMA")

  • settings.meta("IQWiG5")

  • settings.meta("IQWiG6")

  • settings.meta("geneexpr")

  • settings.meta("meta4")

The first command can be used to reproduce meta-analyses from Cochrane reviews conducted with Review Manager 5 (RevMan 5, https://training.cochrane.org/online-learning/core-software/revman) and specifies to use a RevMan 5 layout in forest plots.

The second command can be used to generate forest plots following instructions for authors of the Journal of the American Medical Association (https://jamanetwork.com/journals/jama/pages/instructions-for-authors/).Study labels according to JAMA guidelines can be generated using labels.meta.

The next commands implement the recommendations of the Institute for Quality and Efficiency in Health Care, Germany (IQWiG) accordinging to General Methods 5 and 6, respectively (https://www.iqwig.de/en/about-us/methods/methods-paper/).

The setting "geneexpr" can be used to print p-values in scientific notation and to suppress the calculation of confidence intervals for the between-study variance.

The last setting uses the default settings of R package meta, version 4 or below.

RevMan 5 settings, in detail:

Argument Value Comment
method.random.ci "classic" only available method in RevMan 5
method.tau "DL" only available method in RevMan 5
tau.common FALSE common between-study variance in subgroups
MH.exact FALSE exact Mantel-Haenszel method
RR.Cochrane TRUE calculation of risk ratios
Q.Cochrane TRUE calculation of heterogeneity statistic
layout "RevMan5" layout for forest plots
prediction FALSE no prediction interval
test.overall TRUE print information on test of overall effect
test.subgroup TRUE print information on test for subgroup differences
test.effect.subgroup TRUE print information on test for effect in subgroups
digits.I2 0 number of digits for I-squared measure
digits.tau2 3 number of digits for tau-squared
digits.tau 4 number of digits for square root of tau-squared
CIbracket, "["
CIseparator ", " print confidence intervals as "[., .]"

JAMA settings:

Argument Value Comment
layout "JAMA" layout for forest plots
test.overall TRUE print information on test of overall effect
test.subgroup FALSE print information on test for subgroup differences
test.effect.subgroup FALSE print information on test for effect in subgroups
digits.I2 0 number of digits for I-squared measure
digits.pval 3 number of digits for p-values
CIbracket, "("
CIseparator "-" print confidence intervals as "(.-.)"
zero.pval, TRUE print p-values with leading zero
JAMA.pval, TRUE round p-values to three digits (for 0.001 < p 0.01) or two digits (p > 0.01)

IQWiG, General Methods 5 settings:

Argument Value Comment
method.random.ci "HK" Hartung-Knapp method
prediction TRUE Prediction interval

IQWiG, General Methods 6 settings:

Argument Value Comment
method.random.ci "HK" Hartung-Knapp method
adhoc.hakn.ci "IQWiG6" ad hoc variance correction
method.tau "PM" Paule-Mandel estimator for between-study variance
prediction TRUE Prediction interval

Settings for gene expression data:

Argument Value Comment
scientific.pval TRUE Scientific notation for p-values
method.tau.ci FALSE no confidence interval for
between-study heterogeneity variance

Settings for meta, version 4 or below:

Argument Value Comment
method.tau "DL" DerSimonian-Laird estimator

A list of all arguments with current settings is printed using the command settings.meta("print").

In order to reset all settings of R package meta the command settings.meta("reset") or settings.meta(reset = TRUE) can be used.

Author(s)

Guido Schwarzer sc@imbi.uni-freiburg.de

See Also

gs, forest.meta, print.meta, labels.meta

Examples

# Get listing of current settings
#
settings.meta()

# Meta-analyses using default settings
#
metabin(10, 20, 15, 20)
metaprop(4, 20)
metabin(10, 20, 15, 20, sm = "RD")
metaprop(4, 20, sm = "PLN")

# Change summary measure for R functions metabin and metaprop
# and store old settings
#
oldset <- settings.meta(smbin = "RD", smprop = "PLN")
#
metabin(10, 20, 15, 20)
metaprop(4, 20)

# Use old settings
#
settings.meta(oldset)

# Change level used to calculate confidence intervals
# (99%-CI for studies, 99.9%-CI for pooled effects)
#
metagen(1:3, 2:4 / 10, sm = "MD")
settings.meta(level = 0.99, level.ma = 0.999)
metagen(1:3, 2:4 / 10, sm = "MD")

# Always print a prediction interval
#
settings.meta(prediction = TRUE)
metagen(1:3, 2:4 / 10, sm = "MD")
metagen(4:6, 4:2 / 10, sm = "MD")

# Try to set unknown argument results in a warning
#
try(settings.meta(unknownarg = TRUE))

# Reset to default settings of R package meta
#
settings.meta("reset")
metabin(10, 20, 15, 20)
metaprop(4, 20)
metagen(1:3, 2:4 / 10, sm = "MD")

# Do not back transform results (e.g. print log odds ratios instead
# of odds ratios, print transformed correlations / proportions
# instead of correlations / proportions)
#
settings.meta(backtransf = FALSE)
metabin(10, 20, 15, 20)
metaprop(4, 20)
metacor(c(0.85, 0.7, 0.95), c(20, 40, 10))

# Forest plot using RevMan 5 style
#
settings.meta("RevMan5")
forest(metagen(1:3, 2:4 / 10, sm = "MD", common = FALSE),
  label.left = "Favours A", label.right = "Favours B",
  colgap.studlab = "2cm", colgap.forest.left = "0.2cm")

# Forest plot using JAMA style
#
settings.meta("JAMA")
forest(metagen(1:3, 2:4 / 10, sm = "MD", common = FALSE),
  label.left = "Favours A", label.right = "Favours B",
  colgap.studlab = "2cm", colgap.forest.left = "0.2cm")

# Use slightly different layout for confidence intervals
# (especially useful if upper confidence limit can be negative)
#
settings.meta(CIseparator = " - ")
forest(metagen(-(1:3), 2:4 / 10, sm = "MD", common = FALSE),
  label.left = "Favours A", label.right = "Favours B",
  colgap.studlab = "2cm", colgap.forest.left = "0.2cm")

# Use old settings
#
settings.meta(oldset)


meta documentation built on Sept. 18, 2022, 1:06 a.m.