rr-forestplotmetaformeta-analysis

How to create a forest plot that uses estimates obtained from ClubSandwich?


I'm using metafor and the rma.mv function to conduct a multi-level random effects meta-analysis. I've used the vcalc function to impute the covariance matrix for cluster-robust estimation.

rho <- 0.6

V <- vcalc(vi = df$var_g,
           cluster = df$study,
           obs = df$es_id,
           rho = rho)

res <- rma.mv(yi = g, 
              V = V,
              random = ~ 1 | study / measure, 
              data = df,
              method = "REML",
              test = "t")

summary(res)

Model Results:

estimate      se    tval  df    pval    ci.lb   ci.ub    
  0.2105  0.3563  0.5908   7  0.5732  -0.6320  1.0530  

However, given my dataset, it is desirable to apply a small sample correction, which I understand can be achieved by using vcov = "CR2" within the clubSandwich package. This correction slightly alters the estimate and the 95%CI's.

robust_CIs <- conf_int(res, vcov = "CR2")
print(robust_CIs)
   Coef. Estimate    SE d.f. Lower 95% CI Upper 95% CI
 intrcpt    0.211 0.355 4.98       -0.704         1.13

My question is: since the forest function in metafor uses the res object, how can I instead use the estimate and 95%CI's with the small sample correction from clubSandwich's conf.int in the forest plot?

forest(res,
       slab = df$descriptor,
       addpred = TRUE)

This thread asks a similar problem but there isn't enough detail in the answer for me to understand. I can pull the estimate and CI's from conf.int but not sure how I integrate these into the forest plot.

R - Meta-Analysis - How to create a forest plot with robust estimates from clubSandwich functions


Solution

  • If you use the robust() function from metafor, then you can just pass the resulting object to the forest() function. So you should use:

    res_robust <- robust(res, cluster=study, clubSandwich=TRUE)
    

    and then forest(res_robust).