Below is an overview of the various features provided by the metafor package. Where applicable, function names are also indicated.
The package allows the user to calculate various effect sizes and outcome measures frequently used in meta-analyses (escalc()
function), including:
The package provides a variety of models and analysis approaches, including:
rma()
function),rma.mh()
and rma.peto()
functions),rma.glmm()
function),rma.mv()
function),rma.mv()
function),rma.mv()
function),rma.mv()
function),The package provides functions for creating a variety of meta-analytic plots and figures, including:
funnel()
function),forest()
and addpoly()
functions),baujat()
function),labbe()
function),radial()
function),gosh()
function),profile()
function),qqnorm()
function).R itself also provides extensive and very flexible graphing and plotting capabilities that can be easily adapted to create further plots and figures.
The presence of publication bias (or more accurately, funnel plot asymmetry or "small-study effects") and its potential impact on the results can be examined via a variety of methods, including:
ranktest()
function),regtest()
function),trimfill()
function),hc()
function),fsn()
function),tes()
function),selmodel()
function).The package provides standard and advanced methods for drawing inferences based on meta-analytic data and for assessing the model fit, including:
anova()
function),confint()
function),permutest()
function),robust()
function),cumul()
function),fitted()
and predict()
functions),ranef()
and blup()
functions),logLik()
and deviance()
functions),AIC()
, BIC()
, and fitstats()
functions),simulate()
function).The package is also compatible with the glmulti and MuMIn packages for model selection and (multi)model inference (see here for an illustration), the boot package for bootstrapping (see here for an illustration), and the mice and Amelia packages for multiple imputation (see here for an illustration).
Various methods are available to identify outliers and/or influential studies, and for conducting sensitivity analyses, including:
residuals()
, rstandard()
, and rstudent()
functions),influence()
function),weights()
and hatvalues()
functions),leave1out()
and influence()
functions).The package also includes over 40 datasets from published meta-analyses that can be used for teaching and illustration purposes.
A diagram showing the various functions in the metafor package (and how they related to each other) can be found here. If the package is installed, you should also be able to open this diagram directly from R with the command vignette("diagram")
.
The metafor package is a work in progress and is updated on a regular basis with new functions and options. Under the log of package updates, you can see what changes/updates have been made to the package over the years.