»  Home »  Resources & support »  FAQs »  User-written packages for meta-analysis in Stata

What meta-analysis features are available in Stata?

Title   User-written packages for meta-analysis in Stata
Authors Jonathan A. C. Sterne, University of Bristol
Ross J. Harris, University of Bristol
Roger M. Harbord, University of Bristol
Thomas J. Steichen

Stata does not have a command specifically deisgned for meta-analysis (commands like sem and gsem can be used to fit some meta-analysis models). Stata users, however, have developed an excellent suite of commands for performing meta-analyses.

cover In 2016, Stata published Meta-Analysis in Stata: An Updated Collection from the Stata Journal, Second Edition, which brought together all the Stata Journal articles about meta-analysis. This book is available for purchase at stata-press.com/books/meta-analysis-in-stata/.

The following meta-analysis commands are all described in Meta-Analysis in Stata: An Updated Collection from the Stata Journal, Second Edition. All of them are user-written except 40. sem and gsem.

1. metan

metan is the main Stata meta-analysis command. Its latest version allows the user to input the cell frequencies from the 2 × 2 table for each study (for binary outcomes), the mean and standard deviation in each group (for numerical outcomes), or the effect estimate and standard error from each study. It provides a comprehensive range of methods for meta-analysis, including inverse-variance–weighted meta-analysis, and creates new variables containing the treatment effect estimate and its standard error for each study. These variables can then be used as input to other Stata meta-analysis commands. Meta-analyses may be conducted in subgroups by using the by() option.

All the meta-analysis calculations available in metan are based on standard methods, an overview of which may be found in chapter 15 of Deeks, Altman, and Bradburn (2001).

The version of the metan command that used Stata 7 graphics has been renamed metan7 and is downloaded as part of the metan package currently available on the SSC archive.

The most recent help file for metan provides several clickable examples of using the command.

2. labbe

labbe draws a L’Abbe plot for event data (proportions of successes in the two groups).

3. metaan

metaan performs meta-analysis on effect estimates and standard errors. Included are profile likelihood and permutation estimation, two algorithms not available in metan.

4. metacum

metacum performs cumulative meta-analyses and graphs the results.

5. metap

metap combines p-values by using Fisher’s method, Edgington’s additive method, or Edgington’s normal curve method. It was released in 1999 as a version 6 command (no graphics) and was last updated in 2000. It requires the user to input a p-value for each study.

6. metareg

metareg does meta-regression. It was first released in 1998 and has been updated to take account of improvements in Stata estimation facilities and recent methodological developments. It requires the user to input the treatment effect estimate and its standard error for each study.

7. metafunnel

metafunnel plots funnel plots. It was released in 2004 and uses Stata 8 graphics. It requires the user to input the treatment effect estimate and its standard error for each study.

8. confunnel

confunnel plots contour-enhanced funnel plots. The command has been designed to be flexible, allowing the user to add extra features to the funnel plot.

9. metabias

metabias provides statistical tests for funnel plot asymmetry. It was first released in 1997, but it has been updated to provide recently proposed tests that maintain better control of the false-positive rate than those available in the original command.

10. metatrim

metatrim implements the “trim and fill” method to adjust for publication bias in funnel plots. It requires the user to input the treatment effect estimate and its standard error for each study.

11. extfunnel

extfunnel implements a new range of overlay augmentations to the funnel plot to assess the impact of a new study on an existing meta-analysis.

12. metandi and metandiplot

metandi facilitates the fitting of hierarchical logistic regression models for meta-analysis of diagnostic test accuracy studies. metandiplot produces a graph of the model fit by metandi, which must be the last estimation-class command executed.

13. mvmeta and mvmeta_make

mvmeta performs maximum likelihood, restricted maximum likelihood, or method-of-moments estimation of random-effects multivariate meta-analysis models. mvmeta_make facilitates the preparation of summary datasets from more detailed data.

14. ipdforest

ipdforest is a postestimation command that uses the stored estimates of an xtmixed or xtmelogit command for multilevel linear or logistic regression, respectively.

15. ipdmetan

ipdmetan performs two-stage individual participant data meta-analysis using the inverse-variance method.

16. indirect

indirect performs pairwise indirect treatment comparisons.

17. network setup

network setup imports data from a set of studies reporting count data (events, total number) or quantitative data (mean, standard deviation, total number) for two or more treatments.

18. network import

network import imports a dataset already formatted for network meta-analysis.

19. network table

network table tabulates network meta-analysis data.

20. network pattern

network pattern shows which treatments are used in which studies.

21. network map

network map draws a map of a network; that is, it shows which treatments are directly compared against which other treatments and roughly how much information is available for each treatment and for each treatment comparison.

22. network convert

network convert converts between the three formats described in the help file for network.

23. network query

network query displays the current network settings.

24. network unset

network unset deletes the current network settings.

25. network meta

network meta defines a model to be fit: either the consistency model or the design-by-treatment interaction inconsistency model.

26. network rank

network rank ranks treatments after a network meta-analysis has been fit.

27. network sidesplit

network sidesplit fits the node-splitting model of Dias et al. (2010).

28. network forest

network forest draws a forest plot of network meta-analysis data.

29. networkplot

networkplot plots a network of interventions using nodes and edges.

30. netweight

netweight calculates all direct pairwise summary effect sizes with their variances, creates the design matrix, and estimates the percentage contribution of each direct comparison to the network summary estimates and in the entire network.

31. ifplot

ifplot identifies all triangular and quadratic loops in a network of interventions and estimates the respective inconsistency factors and their uncertainties.

32. netfunnel

netfunnel plots a comparison-adjusted funnel plot for assessing small-study effects within a network of interventions.

33. intervalplot

intervalplot plots the estimated effect sizes and their uncertainties for all pairwise comparisons in a network meta-analysis.

34. netleague

netleague creates a "league table" showing in the off-diagonal cells the relative treatment effects for all possible pairwise comparisons estimated in a network meta-analysis.

35. sucra

sucra gives the surface under the cumulative ranking curves percentages and mean ranks, and produces rankograms (line plots of the probabilities versus ranks) and cumulative ranking plots (line plots of the cumulative probabilities versus ranks) for all treatments in a network of interventions.

36. mdsrank

mdsrank creates the squared matrix containing the pairwise relative effect sizes and plots the resulting values of the unique dimension for each treatment.

37. clusterank

clusterank performs hierarchical cluster analysis to group the competing treatments into meaningful groups.

38. glst

glst calculates a log-linear dose–response regression model using generalized least squares for trend estimation of single or multiple summarized dose–response epidemiological studies. Output from this command may be useful in deriving summary effects and their standard errors for inclusion in meta-analyses of such studies.

39. metamiss

metamiss performs meta-analysis with binary outcomes when some or all studies have missing data.

40. sem and gsem

Describes how to fit fixed- and random-effects meta-analysis models using the sem and gsem commands, introduced in Stata 12 and 13 respectively, for structural equation modeling.

41. metacumbounds

metacumbounds provides z-values, p-values, and Lan-DeMets bounds obtained from fixed- or random-effects meta-analysis. It plots the boundaries and z-values through a process.

42. metasim

metasim simulates a specified number of new studies based on the estimates obtained from a preexisting meta-analysis.

43. metapow

metapow implements an approach to estimating the power of a newly simulated study generated by using the program metasim.

44. metapowplot

metapowplot estimates the power of an updated meta-analysis including a new study and plots each value against a range of sample sizes.

The following commands are documented in the Appendix:

45. metacurve

metacurve models a response as a function of a continuous covariate, optionally adjusting for other variable(s) specified by adjust().

46. metannt

metannt is intended to aid interpretation of meta-analyses of binary data by presenting intervention effect sizes in absolute terms, as the number needed to treat (NNT) and the number of events avoided (or added) per 1,000. The user inputs design parameters, and metannt uses the metan command to calculate the required statistics. This command is available as part of the metan package.

47. metaninf

metaninf is a port of the metainf command to use metan as its analysis engine rather than meta. It was released in 2001 as a version 6 command using version 6 graphics and was last updated in 2004. It requires the user to provide input in the form needed by metan.

48. midas

midas provides statistical and graphical routines for undertaking meta-analysis of diagnostic test performance in Stata.

49. meta_lr

meta_lr graphs positive and negative likelihood ratios in diagnostic tests. It can do stratified meta-analysis of individual estimates. The user must provide the effect estimates (log positive likelihood ratio and log negative likelihood ratio) and their standard errors. Commands meta and metareg are used for internal calculations. This is a version 8 command released in 2004.

50. metaparm

metaparm performs meta-analyses and calculates confidence intervals and p-values for differences or ratios between parameters for different subpopulations for data stored in the parmest format.

51. metaeff

metaeff is a pre-processing command for meta-analysis and a companion to metaan which calculates effect sizes and their standard errors.

Note: There may be commands that appeared in the Stata Journal after the publication of Meta-Analysis in Stata: An Updated Collection from the Stata Journal, Second Edition. For a complete list of meta-analysis commands, type search meta in Stata.


Deeks, J. J., D. G. Altman, and M. J. Bradburn. 2001.
Statistical methods for examining heterogeneity and combining results from several studies in meta-analysis. In Systematic Reviews in Health Care: Meta-Analysis in Context, 2nd Edition, ed. M. Egger, G. Davey Smith, and D. G. Altman. London: BMJ.
Dias, S., N. J. Welton, D. M. Caldwell, and A. E. Ades. 2010.
Checking consistency in mixed treatment comparison meta-analysis. Statistics in Medicine 29: 932–944.





The Stata Blog: Not Elsewhere Classified Find us on Facebook Follow us on Twitter LinkedIn Google+ YouTube
© Copyright 1996–2017 StataCorp LLC   •   Terms of use   •   Privacy   •   Contact us