Skip to content
Prev 349781 / 398506 Next

Trim and fill procedure

Yes, a comparison of the two objects would tell you what's been added.

An object returned by the trimfill() function also has a vector added to it, named 'fill', which indicates whether the data (which are stored in the vector 'yi') are observed or augmented values. So, for example:

library(metafor)

### load BCG vaccine data
data(dat.bcg)

### meta-analysis of the log relative risks using a fixed-effects model
res <- rma(measure="RR", ai=tpos, bi=tneg, ci=cpos, di=cneg, data=dat.bcg, method="FE")

### trim and fill analysis
tmp <- trimfill(res)

### show log relative risks and dummy variable to indicate augmented values
data.frame(tmp$yi, tmp$fill)

### that's in fact how the funnel() function knows how to draw the points when you do:
funnel(tmp)

Best,
Wolfgang