I'm having a problem with metafor's rma-function, which inappropriately (I suppose!) gives both tauˆ2 and Iˆ2 zero values. This questions was previously asked on Stack Overflow, and then it was suggested using (the default) REML estimator of tauˆ2. However, despite using REML, I'm facing this issue. Here are the summary results of my data from rma:
Random-Effects Model (k = 44; tau^2 estimator: REML)
tau^2 (estimated amount of total heterogeneity): 0 (SE = 0.0136)
tau (square root of estimated tau^2 value): 0
I^2 (total heterogeneity / total variability): 0.00%
H^2 (total variability / sampling variability): 1.00
Test for Heterogeneity:
Q(df = 43) = 7.7261, p-val = 1.0000
Model Results:
estimate se zval pval ci.lb ci.ub
0.0589 0.0407 1.4451 0.1484 -0.0210 0.1387
And I think those zero values truly are errors, as Review Manager 5.4 gives the following, reasonable results from the same data:
Heterogeneity: Tau² = 0,01; Chi² = 123,95, df = 43 (P < 0.00001); I² = 65%
Please see my code below. The error most probably is in it, but I just can't figure it out. Could someone help me on this, thank you so much!
metareg <- read.table(text="
effect_size variance study n SE subgroup
0.0368 0.0806 A-1 230 0.0187 A
-0.0509 0.09 A-2 22 0.064 A
-0.1031 0.1081 A-3 16 0.0822 A
0.0731 0.0683 A-4 113 0.0246 A
0.1105 0.0448 A-5 90 0.0223 A
0.1193 0.0484 A-6 28 0.0416 A
0.1405 0.0524 A-7 50 0.0324 A
0.0157 0.0622 A-8 13 0.0692 A
-0.0528 0.0864 A-9 64 0.0367 A
-0.011 0.0799 A-10 13 0.0784 A
0.0713 0.0768 A-11 40 0.0438 A
-0.1307 0.0996 A-12 17 0.0766 A
-0.0658 0.106 A-13 18 0.0767 A
-0.012 0.097 A-14 86 0.0336 A
-0.0163 0.0914 A-15 50 0.0428 A
0.0479 0.0721 A-16 27 0.0517 A
0.11 0.0517 A-17 151 0.0185 A
0.2944 0.0303 A-18 19 0.0399 A
0.0138 0.0713 A-19 16 0.0668 A
0.0082 0.0884 A-20 32 0.0526 A
0.0726 0.0868 A-21 33 0.0513 A
0.1554 0.0163 A-22 10 0.0404 A
0.1247 0.0396 A-23 36 0.0332 A
0.0954 0.0685 A-24 47 0.0382 A
0.0299 0.1061 B-1 401 0.0163 B
-0.0516 0.1111 B-2 68 0.0404 B
-0.0857 0.1165 B-3 47 0.0498 B
-0.1722 0.1083 B-4 23 0.0686 B
-0.0324 0.0807 B-5 16 0.071 B
-0.0581 0.1168 B-6 49 0.0488 B
0.049 0.0982 B-7 43 0.0478 B
0.0885 0.1067 B-8 56 0.0437 B
-0.0056 0.1138 B-9 214 0.0231 B
-0.1039 0.1183 B-10 53 0.0472 B
0.0065 0.1172 B-11 42 0.0528 B
0.1047 0.0957 B-12 72 0.0365 B
0.1337 0.0868 B-13 46 0.0434 B
-0.2632 0.0983 B-14 66 0.0386 B
0.1366 0.0862 B-15 51 0.0411 B
-0.0518 0.1034 B-16 12 0.0928 B
-0.1573 0.11 B-17 17 0.0804 B
0.2218 0.0998 B-18 18 0.0745 B
0.2097 0.0932 B-19 13 0.0847 B
0.0877 0.1061 B-20 14 0.087 B
", header=TRUE)
res.rma <- rma(effect_size, variance, data=metareg)
res.rma
forest(res.rma, slab = paste(metareg$study))
I'm not sure if it helps, but here are the values of respective "intermediate variables" and (probably) correct tauˆ2 and Iˆ2, when these Review Manager's statistical calculations are done in Excel: