Skip to content
Prev 4401 / 5632 Next

[R-meta] Three-level meta-analysis with different sources of dependency

Hi again Wilma,

Following up with a very small correction to the example code in my
previous reply. The argument tdist = TRUE is unnecessary in the rma.mv()
code. The comment (copy-pasted from the example script) is also a bit
misleading because tdist = TRUE is not the same thing as the Knapp-Hartung
adjustment.

The revised code for the multi-level meta-analysis model would be as
follows:

overall <- rma.mv(yi, vi,
                  data = df,
                  level = 95,
                  method = "REML",
                  slab = author_year,
                  random = list(~ 1 | study_id, ~ 1 | esid)) |>
  robust(cluster = study_id, clubSandwich = TRUE)
summary(overall)

Or for the correlated-and-hierarchical effects model:

V <- vcalc(vi, cluster=study_id, obs=esid, data=df, rho=0.6)
overall <- rma.mv(yi, V = V,
                  data = df,
                  level = 95,
                  method = "REML",
                  slab = author_year,
                  random = list(~ 1 | study_id, ~ 1 | esid)) |>
  robust(cluster = study_id, clubSandwich = TRUE)
summary(overall)

James
On Tue, Feb 7, 2023 at 11:54 AM James Pustejovsky <jepusto at gmail.com> wrote: