Houssein Assaad
Senior Statistician and Software Developer
StataCorp LLC
Stata Conference
July 30 , 2020
Philadelphia In-laws' basement
Potential advantages of MA include:
treatment group
control group
vs
ES
e.g. OR, RR, RD, Hedges's \(g\), Cohen's \(d\) etc.
variable 1
variable 2
ES
e.g. correlation coef. \(r\), regression coef \(\beta\) etc.
\(K\) independent studies, each reports:
Model | Assumption | Target of inference |
---|---|---|
common effect (CE) | common value |
|
fixed effects (FE) | fixed | |
Random effects (RE) |
meta set
create variables starting with _meta_ (e.g. _meta_es, _meta_se) to be used with all other commands
etc.
meta funnelplot
meta forestplot
meta summarize
meta esize
meta regress
Binary summary data:
+----------------------------------+
| study nt1 nt0 nc1 nc0 |
|----------------------------------|
| 1 4 119 11 128 |
| 2 6 300 29 274 |
| 3 3 228 11 209 |
| 4 62 13536 248 12619 |
| 5 33 5036 47 5761 |
+----------------------------------+
Precomputed effect size data:
+----------------------+
| study ES ES_se |
|----------------------|
| 1 .03 .125 |
| 2 .12 .147 |
| 3 -.14 .167 |
| 4 1.18 .373 |
| 5 .26 .369 |
+----------------------+
Continuous summary data:
+--------------------------------------------------+
| study n1 m1 sd1 n2 m2 sd2 |
|--------------------------------------------------|
| 1 13 0.096 0.020 14 0.920 0.047 |
| 2 18 -0.000 0.066 11 1.110 0.094 |
| 3 10 0.054 0.088 11 0.956 0.040 |
| 4 15 0.000 0.019 20 0.899 0.098 |
| 5 15 0.036 0.020 10 1.102 0.014 |
+--------------------------------------------------+
Precomputed effect size data: (es and CI)
+----------------------------------------+
| study ES cil ciu |
|----------------------------------------|
| 1 .03 -.2149955 .2749955 |
| 2 .12 -.16811471 .40811471 |
| 3 -.14 -.46731399 .18731399 |
| 4 1.18 .44893343 1.9110666 |
| 5 .26 -.46322671 .98322671 |
+----------------------------------------+
meta esize nt1 nt0 nc1 nc0
meta esize n1 m1 sd1 n2 m2 sd2
meta set ES ES_se
meta set ES cil ciu
Binary summary data
(\(2\times 2\) tables)
Continuous summary data
(sample size, mean, and standard deviation for each group)
Hedges's \(g\), Cohen's \(d\), Glass's \(\Delta_1\) and \(\Delta_2\), and (raw) mean difference \(D\)
log odds-ratio \(\log\)(OR), \(\log\)(ORpeto), log risk-ratio \(\log\)(RR) , and risk difference \(RD\)
Correlation \(r\), \(\log\)(HR), \(\text{logit}\)(\(p\)), etc.
meta esize n1 m1 sd1 n2 m2 sd2
meta esize nt1 nt0 nc1 nc0
meta set ES ES_se
. webuse bcg, clear
(Efficacy of BCG vaccine against tuberculosis)
. keep studylbl npost - nnegc
. describe
------------------------------------------------------------------------------------------
storage display value
variable name type format label variable label
------------------------------------------------------------------------------------------
studylbl str27 %27s Study label
npost int %9.0g Number of TB positive cases in treated group
nnegt long %9.0g Number of TB negative cases in treated group
nposc int %9.0g Number of TB positive cases in control group
nnegc long %9.0g Number of TB negative cases in control group
------------------------------------------------------------------------------------------
group | TB+ | TB- |
---|---|---|
Vaccinated | npost = 4 | nnegt = 119 |
control | nposc = 11 | nnegc = 128 |
each study, \(j\), yield a \(2\times 2\) table, e.g. for study 1:
+--------------------------------------------------------+
| studylbl npost nnegt nposc nnegc |
|--------------------------------------------------------|
1. | Aronson, 1948 4 119 11 128 |
2. | Ferguson & Simes, 1949 6 300 29 274 |
3. | Rosenthal et al., 1960 3 228 11 209 |
+--------------------------------------------------------+
. list in 1/3
their SEs and CIs
computes one of
meta esize
. meta esize npost nnegt nposc nnegc
Meta-analysis setting information
Study information
No. of studies: 13
Study label: Generic <--- controlled by studylabel()
Study size: _meta_studysize
Summary data: npost nnegt nposc nnegc
Effect size
Type: lnoratio <--- controlled by esize()
Label: Log Odds-Ratio <--- controlled by eslabel()
Variable: _meta_es
Zero-cells adj.: None; no zero cells <--- controlled by zerocells()
Precision
Std. Err.: _meta_se
CI: [_meta_cil, _meta_ciu]
CI level: 95% <--- controlled by level()
Model and method <--- controlled by random[()], fixed[()],
Model: Random-effects and common[()]
Method: REML
. meta summarize
Effect-size label: Log Odds-Ratio
Effect size: _meta_es
Std. Err.: _meta_se
Meta-analysis summary Number of studies = 13
Random-effects model Heterogeneity:
Method: REML tau2 = 0.3378
I2 (%) = 92.07
H2 = 12.61
--------------------------------------------------------------------
Study | Log Odds-Ratio [95% Conf. Interval] % Weight
------------------+-------------------------------------------------
Study 1 | -0.939 -2.110 0.233 4.98
Study 2 | -1.666 -2.560 -0.772 6.34
Study 3 | -1.386 -2.677 -0.096 4.49
(Output omitted)
Study 11 | -0.341 -0.560 -0.121 9.88
Study 12 | 0.447 -0.986 1.879 3.97
Study 13 | -0.017 -0.542 0.507 8.45
------------------+-------------------------------------------------
theta | -0.745 -1.110 -0.381
--------------------------------------------------------------------
Test of theta = 0: z = -4.01 Prob > |z| = 0.0001
Test of homogeneity: Q = chi2(12) = 163.16 Prob > Q = 0.0000
. meta esize npost nnegt nposc nnegc, esize(lnrratio) random(dlaird)
. meta update, esize(lnrratio) random(dlaird)
Or equivalently,
Meta-analysis setting information
Study information
No. of studies: 10
(omitted output)
Effect size
Type: lnrratio
Label: Log Risk-Ratio
Variable: _meta_es
Zero-cells adj.: None; no zero cells
(omitted output)
Model and method
Model: Random-effects
Method: DerSimonian-Laird
You may change the default MA model using one of options random[()], common or fixed and the default effect size via option esize()
. meta update, studylabel(studylbl) eslabel("My label")
You may provide more descriptive labels for the studies and the effect size using options studylabel() and eslabel()
Meta-analysis setting information from meta esize
Study information
No. of studies: 13
Study label: studylbl
Study size: _meta_studysize
Summary data: npost nnegt nposc nnegc
Effect size
Type: lnrratio
Label: My label
Variable: _meta_es
Zero-cells adj.: None; no zero cells
Precision
Std. Err.: _meta_se
CI: [_meta_cil, _meta_ciu]
CI level: 95%
Model and method
Model: Random-effects
Method: DerSimonian-Laird
. meta update, zerocells(.2)
// or
. meta update, zerocells(tacc)
We will construct a forest plot for the 1st 4 studies to see the effect of adding study labels and effect size label
. meta update, studylabel(studylbl) eslabel("Log(RR)")
. meta forestplot in 1/4
studylabel(studylbl)
eslabel("Log(RR)")
Forest plot without options studylabel() and eslabel()
. meta query
-> meta esize npost nnegt nposc nnegc , esize(lnrratio) studylabel(studylbl) eslabel(My
> label) random(dlaird)
Meta-analysis setting information from meta esize
Study information
No. of studies: 13
Study label: studylbl
Study size: _meta_studysize
Summary data: npost nnegt nposc nnegc
Effect size
Type: lnrratio
Label: My label
Variable: _meta_es
Zero-cells adj.: None; no zero cells
Precision
Std. Err.: _meta_se
CI: [_meta_cil, _meta_ciu]
CI level: 95%
Model and method
Model: Random-effects
Method: DerSimonian-Laird
Two data sets (bcg.dta and nsaids.dta) will be used throughout this webinar, you may further explore them below
Case study: Efficacy of BCG vaccine against tuberculosis
. webuse bcgset, clear
(Efficacy of BCG vaccine against tuberculosis; set with -meta esize-)
. describe npost - studylbl
------------------------------------------------------------------------------------------
storage display value
variable name type format label variable label
------------------------------------------------------------------------------------------
npost int %9.0g Number of TB positive cases in treated group
nnegt long %9.0g Number of TB negative cases in treated group
nposc int %9.0g Number of TB positive cases in control group
nnegc long %9.0g Number of TB negative cases in control group
latitude byte %9.0g Absolute latitude of the study location (in
degrees)
studylbl str27 %27s Study label
------------------------------------------------------------------------------------------
+----------------------------------------------------------------+
| author npost nnegt nposc nnegc latitude |
|----------------------------------------------------------------|
1. | Aronson 4 119 11 128 44 |
2. | Ferguson & Simes 6 300 29 274 55 |
3. | Rosenthal et al. 3 228 11 209 42 |
+----------------------------------------------------------------+
. list author npost - nnegc latitude in 1/3
. meta esize npost - nnegc, esize(lnrratio) studylabel(studylbl)
. meta forestplot
. meta forest, eform nullrefline
nonsignificant RR
nonoverlapping CIs
Sampling error
Between-study heterogeneity
Total observed heterogeneity
(within-study heterogeneity)
meta summarize and meta forestplot report
Berkey et al (1995) and Borenstein et al (2009) suggested that latitude (as a surrogate for climate) could explain some of the variation in the efficacy of the BCG vaccine
. generate byte latitude_01 = latitude_c > 0
. label define latval 0 "hot climate" 1 "cold climate"
. label values latitude_01 latval
+-------------------------------------------------------+
| studylbl latitude latitude_01 |
|-------------------------------------------------------|
1. | Aronson, 1948 44 cold climate |
2. | Ferguson & Simes, 1949 55 cold climate |
3. | Rosenthal et al., 1960 42 cold climate |
4. | Hart & Sutherland, 1977 52 cold climate |
5. | Frimodt-Moller et al., 1973 13 hot climate |
+-------------------------------------------------------+
. list studylbl latitude latitude_01 in 1/5
. meta forestplot, subgroup(latitude_01) nullrefline rr
summary for each group
Test of \(H_0: \theta_{grp1} = \theta_{grp2}\)
meta forest, subgroup(latitude_01) ///
transform("Vaccine efficacy": efficacy)
Other supported transformations within the transform() option are: corr, exp, invlogit, and tanh.
Random subset
Observed studies
valid conclusions albeit wider CIs, less powerful tests (less info)
systematically different
Studies not included in the MA (missing studies)
(e.g. when smaller studies with nonsignificant findings are suppressed from publication)
our meta-analytic results will be biased and decisions based on them are invalid
meta funnelplot
meta bias
meta trimfill
Small-study effect (potentially due to publication bias)
Little evidence of Small-study effect
which means the individual ES should be distributed randomly around the overall ES
Large and small studies tell the same story about \(\theta\)
Large and small studies tell different stories about \(\theta\)
large studies
small studies
large studies
small studies
. webuse nsaidsset, clear
(Effectiveness of nonsteroidal anti-inflammatory drugs; set with -meta esize-)
. meta funnelplot
Effect-size label: Log Odds-Ratio
Effect size: _meta_es
Std. Err.: _meta_se
Model: Common-effect
Method: Inverse-variance
gap (missing studies ?)
. scalar theta = r(theta) // obtained from previous -meta funnel- command r() results
// position legend at 10 o'clock inside the graph region
. local legopts ring(0) position(10) cols(1) size(small) symxsize(*0.6)
. local opts horizontal range(0 1.6) lpattern(dash) lcolor("red") ///
legend(order(1 2 3 4 5 6) label(6 "95% pseudo CI") `legopts')
. meta funnel, contours(1 5 10) ///
addplot(function theta-1.96*x, `opts' || function theta+1.96*x, `opts')
. meta bias, harbord
Effect-size label: Log Odds-Ratio
Effect size: _meta_es
Std. Err.: _meta_se
Regression-based Harbord test for small-study effects
Random-effects model
Method: REML
H0: beta1 = 0; no small-study effects
beta1 = 3.03
SE of beta1 = 0.741
z = 4.09
Prob > |z| = 0.0000
Nonparametric trim-and-fill analysis of publication bias
Linear estimator, imputing on the left
Iteration Number of studies = 47
Model: Random-effects observed = 37
Method: REML imputed = 10
Pooling
Model: Random-effects
Method: REML
---------------------------------------------------------------
Studies | Log Odds-Ratio [95% Conf. Interval]
---------------------+-----------------------------------------
Observed | 1.322 1.031 1.613
Observed + Imputed | 1.035 0.726 1.343
---------------------------------------------------------------
. meta trimfill, funnel(contours(1 5 10) legend(`legopts'))
Prefer to avoid typing commands ? Everything I have showed you can be done in the meta control panel with few mouse clicks
meta set
meta esize
meta summarize
meta forestplot
meta labbeplot
meta regress
estat bubbleplot
meta funnelplot
meta bias
meta trimfill