### calculate log relative risks and corresponding sampling variances
dat <- escalc(measure="RR", ai=tpos, bi=tneg, ci=cpos, di=cneg, data=dat.bcg)
### meta-analysis of the log relative risks using a random-effects model
res <- rma(yi, vi, data=dat)
### BLUPs of the random effects
blup(res)
Run the code above in your browser using DataLab