Skip to content

[R-meta] Residuals for random effect

2 messages · Wolfgang Viechtbauer, Lukas Dylewski

#
Hi Lukas,

I assume you are after the BLUPs of the random effects. You can obtain those with the ranef() function. So, just do ranef(res1).

Best,
Wolfgang

-----Original Message-----
From: R-sig-meta-analysis [mailto:r-sig-meta-analysis-bounces at r-project.org] On Behalf Of Lukas Dylewski
Sent: Tuesday, 10 September, 2019 14:30
To: r-sig-meta-analysis at r-project.org
Subject: [R-meta] Residuals for random effect

Dear All,

I would like to calculate residuals for a random effect.  Could I calculate
the residual values after subtracting the predicted influence of the
study?
I would like to get the same residuals value for each study level (in the
model below coded pub).

My model:
res1 <- rma.mv(yi, vi, mods = ~ logmass +
I(logmass^2),random=~1|pub,data=metaan, method="REML")

Regards
Lukasz
#
Thank you !

W dniu ?r., 11.09.2019 o 09:17 Viechtbauer, Wolfgang (SP) <
wolfgang.viechtbauer at maastrichtuniversity.nl> napisa?(a):