metafor (version 3.0-2)

leave1out: Leave-One-Out Diagnostics for 'rma' Objects

Description

The functions repeatedly fit the specified model, leaving out one observation/study at a time.

Usage

leave1out(x, …)

# S3 method for rma.uni leave1out(x, digits, transf, targs, progbar=FALSE, …) # S3 method for rma.mh leave1out(x, digits, transf, targs, progbar=FALSE, …) # S3 method for rma.peto leave1out(x, digits, transf, targs, progbar=FALSE, …)

Arguments

x

an object of class "rma.mh", "rma.peto", or "rma.uni".

digits

integer to specify the number of decimal places to which the printed results should be rounded. If unspecified, the default is to take the value from the object.

transf

an optional argument to specify a function that should be used to transform the model coefficients and interval bounds (e.g., transf=exp; see also transf). If unspecified, no transformation is used.

targs

optional arguments needed by the function specified under transf.

progbar

logical to specify whether a progress bar should be shown (the default is FALSE).

other arguments.

Value

An object of class "list.rma". The object is a list containing the following components:

estimate

estimated (average) outcomes.

se

corresponding standard errors.

zval

corresponding test statistics.

pval

corresponding p-values.

ci.lb

lower bounds of the confidence intervals.

ci.ub

upper bounds of the confidence intervals.

Q

test statistics for the test of heterogeneity.

Qp

corresponding p-values.

tau2

estimated amount of heterogeneity (only for random-effects models).

I2

values of I^2.

H2

values of H^2.

When the model was fitted with test="t" or test="knha", then zval is called tval in the object that is returned by the function.

The object is formatted and printed with print.list.rma.

Details

For "rma.uni" objects, the model specified via x must be a model without moderators (i.e., either a fixed- or a random-effects model).

References

Viechtbauer, W. (2010). Conducting meta-analyses in R with the metafor package. Journal of Statistical Software, 36(3), 1--48. https://doi.org/10.18637/jss.v036.i03

Viechtbauer, W., & Cheung, M. W.-L. (2010). Outlier and influence diagnostics for meta-analysis. Research Synthesis Methods, 1(2), 112--125. https://doi.org/10.1002/jrsm.11

See Also

rma.uni, rma.mh, rma.peto

Examples

Run this code
# NOT RUN {
### calculate log risk ratios and corresponding sampling variances
dat <- escalc(measure="RR", ai=tpos, bi=tneg, ci=cpos, di=cneg, data=dat.bcg)

### random-effects model
res <- rma(yi, vi, data=dat)

### leave-one-out analysis
leave1out(res)
leave1out(res, transf=exp)

### meta-analysis of the (log) risk ratios using the Mantel-Haenszel method
res <- rma.mh(measure="RR", ai=tpos, bi=tneg, ci=cpos, di=cneg, data=dat.bcg)

### leave-one-out analysis
leave1out(res)
leave1out(res, transf=exp)

### meta-analysis of the (log) odds ratios using Peto's method
res <- rma.peto(ai=tpos, bi=tneg, ci=cpos, di=cneg, data=dat.bcg)

### leave-one-out analysis
leave1out(res)
leave1out(res, transf=exp)
# }

Run the code above in your browser using DataLab