The results of some of the meta-analyses presented in the paper titled “Meta-analysis of laparoscopic vs. open resection of gastric gastrointestinal stromal tumors” by L. Ye et al (2017) are re-analyzed and reported here. In addition, manual calculations in R are also presented, besides using the functions in R packages.

# Type the data
Matthews = c(169, 58.8,21,160, 48.1,12)
Mochizuki = c(111.3, 33.8,12, 124.5,41.6, 10)
Ishikawa = c(115, 56, 21,134 ,33, 25)
Pitsinis = c( 118,55, 14, 165,108, 7)
Catena = c( 129.6, 36.1,15, 110.8,38.1 , 13)
Goh = c(107.5,8.8,6, 157.5 ,53.6, 7)
Wu = c(130, 17.5,18,105, 32.5,30)
Karakousis = c(96, 38,40, 89,54.8, 40)
Dal = c(135, 45, 17,157 ,60, 29)
Pucci = c( 90, 45,68, 125,60 , 88)
Wan = c(145,26.1,14, 95 ,42.5, 39)
Kim = c(160, 76.3,57,191, 85.3,47)
Melstrom = c(119.8, 62.2,24, 154.3,53.5, 14)
Vogelaere = c( 116.6,26.1, 30, 119.6,48.5, 32)
Shu = c( 147.8, 59.3,15, 139.2,62.1 , 21)
Lee = c(48.5,16,37, 155 ,48.1, 16)
Lin = c(124.1, 50.3,23,196.5, 65.8,23)
Kasetsemwiriya = c(152.3, 64.8,23, 198.5,75.1, 10)
Takahashi = c(123.8, 44.8, 12,119.5 ,44.2, 15)
Sista = c( 130,70, 282, 150,79, 384)
Cal = c(106.6, 40.1,90, 119.9,59.9 , 66)
deAngelis = c(146.6,50.2,18, 113.3 ,42.9, 21)
Hsiao = c(129.3, 28.2,25,136.8, 27.5,25)
Piessen = c(245, 40,30, 228,52, 33)
Yan = c(138.8, 69.2, 158,173.3 ,74.5, 68)

# Make a data frame
dat = as.data.frame(rbind(Matthews,Mochizuki,Ishikawa, Pitsinis,Catena, Goh,Wu, Karakousis, Dal,
                          Pucci,Wan,Kim, Melstrom,Vogelaere,Shu,Lee,Lin,Kasetsemwiriya,Takahashi,
                          Sista,Cal,deAngelis,Hsiao,Piessen,Yan))
colnames(dat) = c("m.t","sd.t","n.t","m.c","sd.c","n.c")
# Print the data
dat
##                  m.t sd.t n.t   m.c  sd.c n.c
## Matthews       169.0 58.8  21 160.0  48.1  12
## Mochizuki      111.3 33.8  12 124.5  41.6  10
## Ishikawa       115.0 56.0  21 134.0  33.0  25
## Pitsinis       118.0 55.0  14 165.0 108.0   7
## Catena         129.6 36.1  15 110.8  38.1  13
## Goh            107.5  8.8   6 157.5  53.6   7
## Wu             130.0 17.5  18 105.0  32.5  30
## Karakousis      96.0 38.0  40  89.0  54.8  40
## Dal            135.0 45.0  17 157.0  60.0  29
## Pucci           90.0 45.0  68 125.0  60.0  88
## Wan            145.0 26.1  14  95.0  42.5  39
## Kim            160.0 76.3  57 191.0  85.3  47
## Melstrom       119.8 62.2  24 154.3  53.5  14
## Vogelaere      116.6 26.1  30 119.6  48.5  32
## Shu            147.8 59.3  15 139.2  62.1  21
## Lee             48.5 16.0  37 155.0  48.1  16
## Lin            124.1 50.3  23 196.5  65.8  23
## Kasetsemwiriya 152.3 64.8  23 198.5  75.1  10
## Takahashi      123.8 44.8  12 119.5  44.2  15
## Sista          130.0 70.0 282 150.0  79.0 384
## Cal            106.6 40.1  90 119.9  59.9  66
## deAngelis      146.6 50.2  18 113.3  42.9  21
## Hsiao          129.3 28.2  25 136.8  27.5  25
## Piessen        245.0 40.0  30 228.0  52.0  33
## Yan            138.8 69.2 158 173.3  74.5  68
library(meta)
## Loading 'meta' package (version 4.8-4).
## Type 'help(meta)' for a brief overview.
# call the metacont
mod = metacont(n.t,m.t,sd.t,n.c,m.c,sd.c,
data=dat,studlab=rownames(dat),sm="SMD")
# print the meta-analysis
mod
##                    SMD             95%-CI %W(fixed) %W(random)
## Matthews        0.1589 [-0.5515;  0.8694]       1.5        3.7
## Mochizuki      -0.3385 [-1.1850;  0.5079]       1.1        3.2
## Ishikawa       -0.4156 [-1.0025;  0.1714]       2.3        4.1
## Pitsinis       -0.5949 [-1.5238;  0.3341]       0.9        2.9
## Catena          0.4928 [-0.2628;  1.2485]       1.4        3.5
## Goh            -1.1620 [-2.3766;  0.0526]       0.5        2.2
## Wu              0.8810 [ 0.2684;  1.4936]       2.1        4.0
## Karakousis      0.1470 [-0.2919;  0.5859]       4.1        4.6
## Dal            -0.3930 [-0.9975;  0.2116]       2.1        4.0
## Pucci          -0.6451 [-0.9698; -0.3205]       7.4        5.0
## Wan             1.2637 [ 0.6039;  1.9236]       1.8        3.8
## Kim            -0.3823 [-0.7721;  0.0075]       5.1        4.8
## Melstrom       -0.5705 [-1.2434;  0.1024]       1.7        3.8
## Vogelaere      -0.0754 [-0.5737;  0.4229]       3.1        4.4
## Shu             0.1379 [-0.5255;  0.8014]       1.8        3.8
## Lee            -3.5755 [-4.4944; -2.6566]       0.9        3.0
## Lin            -1.2150 [-1.8486; -0.5814]       1.9        3.9
## Kasetsemwiriya -0.6633 [-1.4251;  0.0984]       1.3        3.5
## Takahashi       0.0938 [-0.6658;  0.8533]       1.4        3.5
## Sista          -0.2652 [-0.4196; -0.1109]      32.8        5.4
## Cal            -0.2677 [-0.5868;  0.0513]       7.7        5.0
## deAngelis       0.7031 [ 0.0524;  1.3538]       1.8        3.9
## Hsiao          -0.2650 [-0.8220;  0.2919]       2.5        4.2
## Piessen         0.3597 [-0.1390;  0.8583]       3.1        4.4
## Yan            -0.4855 [-0.7733; -0.1976]       9.4        5.1
## 
## Number of studies combined: k = 25
## 
##                          SMD             95%-CI     z  p-value
## Fixed effect model   -0.2543 [-0.3427; -0.1659] -5.64 < 0.0001
## Random effects model -0.2384 [-0.4710; -0.0058] -2.01   0.0445
## 
## Quantifying heterogeneity:
##  tau^2 = 0.2534; H = 2.34 [1.96; 2.79]; I^2 = 81.7% [73.9%; 87.2%]
## 
## Test of heterogeneity:
##       Q d.f.  p-value
##  131.22   24 < 0.0001
## 
## Details on meta-analytical method:
## - Inverse variance method
## - DerSimonian-Laird estimator for tau^2
## - Hedges' g (bias corrected standardised mean difference)
# call the metacont
mod2 = metacont(n.t,m.t,sd.t,n.c,m.c,sd.c,
data=dat,studlab=rownames(dat),sm="MD")
# print the meta-analysis
mod2
##                       MD                95%-CI %W(fixed) %W(random)
## Matthews          9.0000 [ -28.0553;  46.0553]       1.5        3.6
## Mochizuki       -13.2000 [ -45.3015;  18.9015]       2.0        3.9
## Ishikawa        -19.0000 [ -46.2212;   8.2212]       2.7        4.1
## Pitsinis        -47.0000 [-132.0353;  38.0353]       0.3        1.6
## Catena           18.8000 [  -8.8169;  46.4169]       2.6        4.1
## Goh             -50.0000 [ -90.3262;  -9.6738]       1.2        3.4
## Wu               25.0000 [  10.8363;  39.1637]      10.0        4.7
## Karakousis        7.0000 [ -13.6659;  27.6659]       4.7        4.5
## Dal             -22.0000 [ -52.5689;   8.5689]       2.2        3.9
## Pucci           -35.0000 [ -51.4787; -18.5213]       7.4        4.6
## Wan              50.0000 [  30.8995;  69.1005]       5.5        4.5
## Kim             -31.0000 [ -62.4173;   0.4173]       2.0        3.9
## Melstrom        -34.5000 [ -71.9783;   2.9783]       1.4        3.6
## Vogelaere        -3.0000 [ -22.2251;  16.2251]       5.4        4.5
## Shu               8.6000 [ -31.4750;  48.6750]       1.3        3.4
## Lee            -106.5000 [-130.6258; -82.3742]       3.5        4.3
## Lin             -72.4000 [-106.2484; -38.5516]       1.8        3.8
## Kasetsemwiriya  -46.2000 [ -99.7529;   7.3529]       0.7        2.8
## Takahashi         4.3000 [ -29.5056;  38.1056]       1.8        3.8
## Sista           -20.0000 [ -31.3658;  -8.6342]      15.6        4.8
## Cal             -13.3000 [ -29.9575;   3.3575]       7.2        4.6
## deAngelis        33.3000 [   3.7285;  62.8715]       2.3        4.0
## Hsiao            -7.5000 [ -22.9402;   7.9402]       8.4        4.7
## Piessen          17.0000 [  -5.7957;  39.7957]       3.9        4.4
## Yan             -34.5000 [ -55.2357; -13.7643]       4.7        4.5
## 
## Number of studies combined: k = 25
## 
##                            MD              95%-CI     z  p-value
## Fixed effect model    -9.6466 [-14.1307; -5.1625] -4.22 < 0.0001
## Random effects model -13.4975 [-26.7784; -0.2166] -1.99   0.0464
## 
## Quantifying heterogeneity:
##  tau^2 = 919.4266; H = 2.79 [2.38; 3.28]; I^2 = 87.2% [82.3%; 90.7%]
## 
## Test of heterogeneity:
##       Q d.f.  p-value
##  187.39   24 < 0.0001
## 
## Details on meta-analytical method:
## - Inverse variance method
## - DerSimonian-Laird estimator for tau^2
forest(mod)

forest(mod2)

#Step-by-Step Calculations in R
# First get the pooled sd to calculate the SMD
pooled.sd = sqrt(((dat$n.t-1)*dat$sd.t^2+(dat$n.c-1)*dat$sd.c^2)/(dat$n.t+dat$n.c-2))
# Print the SD
pooled.sd
##  [1] 55.24097 37.51125 44.93834 75.84923 37.03650 40.02835 27.91193
##  [8] 47.15422 55.02066 53.98864 38.98045 80.48351 59.20599 39.30115
## [15] 60.96264 29.34586 58.56505 67.95135 44.46500 75.32263 49.43404
## [22] 46.39690 27.85220 46.68134 70.82685
# The standardized mean difference(SMD)
g = (dat$m.t-dat$m.c)/pooled.sd
# Print the SMD
g
##  [1]  0.16292255 -0.35189442 -0.42280154 -0.61965035  0.50760736
##  [6] -1.24911458  0.89567421  0.14844908 -0.39984982 -0.64828459
## [11]  1.28269444 -0.38517205 -0.58271132 -0.07633364  0.14107002
## [16] -3.62913220 -1.23623220 -0.67989818  0.09670528 -0.26552445
## [21] -0.26904538  0.71772035 -0.26927856  0.36417121 -0.48710339
# Hedges correction factor
N = dat$n.t+dat$n.c
J = 1- 3/(4*N-9)
# Print the correction factor J
J
##  [1] 0.9756098 0.9620253 0.9828571 0.9600000 0.9708738 0.9302326 0.9836066
##  [8] 0.9903537 0.9828571 0.9951220 0.9852217 0.9926290 0.9790210 0.9874477
## [15] 0.9777778 0.9852217 0.9828571 0.9756098 0.9696970 0.9988701 0.9951220
## [22] 0.9795918 0.9842932 0.9876543 0.9966480
# now the Hedges g*
gstar = J*g
# Print it
gstar
##  [1]  0.15894883 -0.33853134 -0.41555351 -0.59486433  0.49282268
##  [6] -1.16196705  0.88099103  0.14701710 -0.39299525 -0.64512222
## [11]  1.26373836 -0.38233295 -0.57048660 -0.07537547  0.13793513
## [16] -3.57549970 -1.21503965 -0.66331530  0.09377482 -0.26522443
## [21] -0.26773296  0.70307299 -0.26504905  0.35967526 -0.48547064
# Variance of SMD
var.gstar = (dat$n.t+dat$n.c)/(dat$n.t*dat$n.c)
+ gstar^2/(2*(dat$n.t+dat$n.c-3.94))
##  [1] 4.346994e-04 3.172853e-03 2.052838e-03 1.037115e-02 5.047261e-03
##  [6] 7.451255e-02 8.807821e-03 1.420854e-04 1.836011e-03 1.368482e-03
## [11] 1.627634e-02 7.304541e-04 4.777671e-03 4.892751e-05 2.967264e-04
## [16] 1.302915e-01 1.755018e-02 7.570323e-03 1.906703e-04 5.312509e-05
## [21] 2.356995e-04 7.049510e-03 7.626031e-04 1.095211e-03 5.306713e-04
# Print it
var.gstar
##  [1] 0.130952381 0.183333333 0.087619048 0.214285714 0.143589744
##  [6] 0.309523810 0.088888889 0.050000000 0.093306288 0.026069519
## [11] 0.097069597 0.038820455 0.113095238 0.064583333 0.114285714
## [16] 0.089527027 0.086956522 0.143478261 0.150000000 0.006150266
## [21] 0.026262626 0.103174603 0.080000000 0.063636364 0.021034996
lowCI.gstar = gstar-1.96*sqrt(var.gstar)
upCI.gstar = gstar+1.96*sqrt(var.gstar)
# Print the CIs and the SMD
cbind(lowCI.gstar, gstar, upCI.gstar)
##       lowCI.gstar       gstar   upCI.gstar
##  [1,] -0.55032309  0.15894883  0.868220760
##  [2,] -1.17775320 -0.33853134  0.500690525
##  [3,] -0.99572360 -0.41555351  0.164616577
##  [4,] -1.50216803 -0.59486433  0.312439364
##  [5,] -0.24988477  0.49282268  1.235530136
##  [6,] -2.25241038 -1.16196705 -0.071523714
##  [7,]  0.29663193  0.88099103  1.465350129
##  [8,] -0.29125223  0.14701710  0.585286422
##  [9,] -0.99169838 -0.39299525  0.205707875
## [10,] -0.96158496 -0.64512222 -0.328659486
## [11,]  0.65308088  1.26373836  1.874395846
## [12,] -0.76850993 -0.38233295  0.003844035
## [13,] -1.22962746 -0.57048660  0.088654251
## [14,] -0.57347520 -0.07537547  0.422724248
## [15,] -0.52466581  0.13793513  0.800536063
## [16,] -4.16195262 -3.57549970 -2.989046783
## [17,] -1.79301212 -1.21503965 -0.637067184
## [18,] -1.40573438 -0.66331530  0.079103780
## [19,] -0.66532992  0.09377482  0.852879552
## [20,] -0.41893474 -0.26522443 -0.111514108
## [21,] -0.58536562 -0.26773296  0.049899694
## [22,]  0.07350524  0.70307299  1.332640747
## [23,] -0.81942077 -0.26504905  0.289322666
## [24,] -0.13475921  0.35967526  0.854109744
## [25,] -0.76973820 -0.48547064 -0.201203091
# The individual weight
w = 1/var.gstar
w
##  [1]   7.636364   5.454545  11.413043   4.666667   6.964286   3.230769
##  [7]  11.250000  20.000000  10.717391  38.358974  10.301887  25.759615
## [13]   8.842105  15.483871   8.750000  11.169811  11.500000   6.969697
## [19]   6.666667 162.594595  38.076923   9.692308  12.500000  15.714286
## [25]  47.539823
# The total weight
tot.w = sum(w)
tot.w
## [1] 511.2536
# And the relative weight
rel.w = w/tot.w
rel.w
##  [1] 0.014936547 0.010668962 0.022323643 0.009127890 0.013621978
##  [6] 0.006319308 0.022004734 0.039119527 0.020962964 0.075029246
## [11] 0.020150247 0.050385198 0.017294949 0.030286085 0.017114793
## [16] 0.021847887 0.022493728 0.013632562 0.013039842 0.318031180
## [21] 0.074477561 0.018957925 0.024449704 0.030736771 0.092986769
# Meta-estimate
M = sum(rel.w*gstar)
M
## [1] -0.296462
# The variance of M
var.M = 1/tot.w
var.M
## [1] 0.001955976
# The SE
se.M = sqrt(var.M)
se.M
## [1] 0.04422642
# The lower 95% CI bound
lowCI.M = M-1.96*se.M
lowCI.M
## [1] -0.3831458
# The upper 95% CI bound
upCI.M = M+1.96*se.M
upCI.M
## [1] -0.2097782
# Compute z
z = M/se.M
z
## [1] -6.703278
# Compute p-value
pval = 2*(1-pnorm(abs(z)))
pval
## [1] 2.037948e-11
# The Q statistic
Q = sum(w*gstar^2)-(sum(w*gstar))^2/tot.w
Q
## [1] 211.6667
# The degrees of freedom from 6 studies
df= 6-1
# C quantity
C = tot.w - sum(w^2)/tot.w
C
## [1] 443.6353
# The tau-square estimate
tau2 = (Q-df)/C
tau2
## [1] 0.4658483
# Now compute the weights incorporating heterogeneity
wR = 1/(var.gstar+tau2)
wR
##  [1] 1.675601 1.540401 1.806791 1.470299 1.640856 1.289703 1.802656
##  [8] 1.938555 1.788414 2.032860 1.776458 1.981498 1.727284 1.885257
## [15] 1.723740 1.800584 1.808957 1.641156 1.623777 2.118651 2.032062
## [22] 1.757399 1.832011 1.888629 2.053880
# The total weight
tot.wR = sum(wR)
tot.wR
## [1] 44.63748
# The relative weight
rel.wR = wR/tot.wR
rel.wR
##  [1] 0.03753799 0.03450914 0.04047700 0.03293866 0.03675960 0.02889284
##  [7] 0.04038435 0.04342885 0.04006531 0.04554155 0.03979746 0.04439090
## [13] 0.03869583 0.04223485 0.03861642 0.04033795 0.04052552 0.03676633
## [19] 0.03637698 0.04746349 0.04552368 0.03937047 0.04104199 0.04231039
## [25] 0.04601246
# The meta-estimate
MR = sum(rel.wR*gstar)
MR
## [1] -0.276899
# The variance of MR
var.MR = 1/tot.wR
var.MR
## [1] 0.0224027
# The SE of MR
se.MR = sqrt(var.MR)
se.MR
## [1] 0.1496753
# The lower bound of 95% CI
lowCI.MR = MR - 1.96*se.MR
lowCI.MR
## [1] -0.5702626
# The upper 95% CI
upCI.MR = MR + 1.96*se.MR
upCI.MR
## [1] 0.01646461
# The z value
zR = MR/se.MR
zR
## [1] -1.849998
# The p-value
pval.R = 2*(1-pnorm(abs(zR)))
pval.R
## [1] 0.06431386
# The summary table
sumTab = data.frame(
SMD = round(gstar,4),
lowCI = round(lowCI.gstar,4),
upperCI = round(upCI.gstar,4),
pctW.fixed = round(rel.w*100,2),
pctW.random = round(rel.wR*100,2))
rownames(sumTab) = rownames(dat)
# Print it
sumTab
##                    SMD   lowCI upperCI pctW.fixed pctW.random
## Matthews        0.1589 -0.5503  0.8682       1.49        3.75
## Mochizuki      -0.3385 -1.1778  0.5007       1.07        3.45
## Ishikawa       -0.4156 -0.9957  0.1646       2.23        4.05
## Pitsinis       -0.5949 -1.5022  0.3124       0.91        3.29
## Catena          0.4928 -0.2499  1.2355       1.36        3.68
## Goh            -1.1620 -2.2524 -0.0715       0.63        2.89
## Wu              0.8810  0.2966  1.4654       2.20        4.04
## Karakousis      0.1470 -0.2913  0.5853       3.91        4.34
## Dal            -0.3930 -0.9917  0.2057       2.10        4.01
## Pucci          -0.6451 -0.9616 -0.3287       7.50        4.55
## Wan             1.2637  0.6531  1.8744       2.02        3.98
## Kim            -0.3823 -0.7685  0.0038       5.04        4.44
## Melstrom       -0.5705 -1.2296  0.0887       1.73        3.87
## Vogelaere      -0.0754 -0.5735  0.4227       3.03        4.22
## Shu             0.1379 -0.5247  0.8005       1.71        3.86
## Lee            -3.5755 -4.1620 -2.9890       2.18        4.03
## Lin            -1.2150 -1.7930 -0.6371       2.25        4.05
## Kasetsemwiriya -0.6633 -1.4057  0.0791       1.36        3.68
## Takahashi       0.0938 -0.6653  0.8529       1.30        3.64
## Sista          -0.2652 -0.4189 -0.1115      31.80        4.75
## Cal            -0.2677 -0.5854  0.0499       7.45        4.55
## deAngelis       0.7031  0.0735  1.3326       1.90        3.94
## Hsiao          -0.2650 -0.8194  0.2893       2.44        4.10
## Piessen         0.3597 -0.1348  0.8541       3.07        4.23
## Yan            -0.4855 -0.7697 -0.2012       9.30        4.60