[R-meta] Help with estimate adjustment
Dr. Guido Schwarzer
gu|do@@chw@rzer @end|ng |rom un|k||n|k-|re|burg@de
Wed Jun 21 15:57:45 CEST 2023
Massimo,
You could either conduct a subgroup analysis (if your covariate has few different values) or a meta-regression. Here is a fictitious example.
library(meta)
dat <- data.frame(n = rep(100, 6), mean = 1:6, sd = rep(1, 6), age = runif(6, 40, 60))
dat$age.c <- dat$age - mean(dat$age)
dat$agecat <- factor(dat$age > 50, levels = c(FALSE, TRUE), labels = c("<= 50 years", "> 50 years"))
m <- metamean(n, mean, sd, data = dat)
m
# Subgroup analysis
update(m, subgroup = agecat)
# Subgroup analysis assuming a common between-study variance in subgroups
update(m, subgroup = agecat, tau.common = TRUE)
metareg(m, ~ agecat) # same result
# Meta-regression using continuous covariate
metareg(m, ~ age.c)
Best,
Guido
More information about the R-sig-meta-analysis
mailing list