[R-meta] Between study correlation between two different outcomes
Viechtbauer, Wolfgang (SP)
wolfgang.viechtbauer at maastrichtuniversity.nl
Thu May 3 19:44:56 CEST 2018
Dear Matthias,
Can you explain the data structure a bit more? I assume you have two rows for each level of 'ID', the first row for outcome 1 and the second row for outcome 2 and that 'type_outcome' is a dummy variable to indicate the outcome. Is that correct?
Then the output should include the correlation between the underlying true effects (rho). You can get a CI for this with the confint() function. To test its significance, you can conduct a likelihood ratio test. This should do it:
rp <- rma.mv(yi, vi, data=pd, mod = ~ factor(type_outcome) -1, random= ~ type_outcome | ID)
rp0 <- rma.mv(yi, vi, data=pd, mod = ~ factor(type_outcome) -1, random= ~ type_outcome | ID, rho=0)
anova(rp, rp0)
confint(rp, rho=1)
Two notes:
The model you are fitting uses struct="CS" by default. This assumes that the amount of heterogeneity is the same for the two outcomes, which may not be appropriate. So you might want to use struct="UN".
Also, I assume the two outcomes are measured in the same subjects. In that case, the sampling errors of the two outcomes are correlated. So the V matrix (the second argument for the rma.mv()) function is not diagonal, but also should include the covariances. If you do not account for this, the correlation between the underlying true effects is very likely an overestimate.
Best,
Wolfgang
-----Original Message-----
From: R-sig-meta-analysis [mailto:r-sig-meta-analysis-bounces at r-project.org] On Behalf Of Aulbach, Matthias B
Sent: Thursday, 03 May, 2018 16:52
To: r-sig-meta-analysis at r-project.org
Subject: [R-meta] Between study correlation between two different outcomes
Hi,
I am conducting a meta-analysis, using the great metafor package. I have run into the problem of dependency when using more than one outcome from the same set of studies. In an earlier attempt, I had run two univariate meta-analyses and then used the outcome of one outcome as a predictor in a meta-regression with the other outcome as the dependent variable. But that ignores the within-study correlation between the two, so I'd like to improve that. So I'd like to handle that using a multivariate meta-analysis, using rma.mv and this line of code (with yi denoting the effect sizes, vi their standard errors, type_outcome the kind of outcome that was measured, and ID as the study identifier):
rp <- rma.mv(yi, vi, data=pd, mod = ~ factor(type_outcome) -1, random= ~ type_outcome | ID)
This nicely gives me the different effects for the two kinds of outcomes. However, what I am so desperately interested in is the between-study correlation between the two outcomes, i.e. if there's a strong effect on one outcome, is there also a strong effect on the other (or not)? Is there a way to get that information, including confidence intervals and a significance test for the correlation coefficient?
Any kind of advice is deeply appreciated!
Best,
Matthias
More information about the R-sig-meta-analysis
mailing list