[R-meta] predicted intervals in metafor

Viechtbauer Wolfgang (SP) wolfgang.viechtbauer at maastrichtuniversity.nl
Fri Dec 15 09:38:02 CET 2017

Dear Raynaud,

Once you have the SMD values and corresponding sampling variances, the code is the same. Here is an example:


### load data
dat <- get(data(dat.normand1999))

### calculate SMDs and corresponding sampling variances
dat <- escalc(measure="SMD", m1i=m1i, sd1i=sd1i, n1i=n1i, m2i=m2i, sd2i=sd2i, n2i=n2i, data=dat)

### meta-analysis of SMD values using a random-effects model
res <- rma(yi, vi, data=dat)

### get prediction/credibility interval

If you have calculated the SMD values and variances yourself, you can skip the escalc() step and go straight to rma(). Adjust variables names as needed.


-----Original Message-----
From: R-sig-meta-analysis [mailto:r-sig-meta-analysis-bounces at r-project.org] On Behalf Of Raynaud Armstrong
Sent: Friday, 15 December, 2017 1:37
To: r-sig-meta-analysis at r-project.org
Subject: [R-meta] predicted intervals in metafor

Hi there,
I would like to calculate predicted intervals in addition to my pooled
estimate and CIs as I have plenty of between-study variation in my
meta-analysis. I am using metafor package and my summary estimated is an
effect size (SMD) and not odds ratios. The examples I have come across
mainly focus on odds ratios and I wonder what to do for SMDs.
I would appreciate if someone could suggest what function to use.

Thank you,

More information about the R-sig-meta-analysis mailing list