*! version 3.0.2 14Nov2023

Title

metapreg -- Fixed-effects, random-effects and mixed-effects meta-analysis, meta-regression and network meta-analysis
of proportions with binomial distribution and logit, loglog and cloglog links

Syntax

[by varlist:]
metapreg depvars
[indepvars]
[if] [in]
,
studyid(studyid)
[options]

depvars has the form n N in a basic/comparative/abnetwork meta-analysis, a b c d in matched(mcbnetwork) studies, and ab ac N in pcbnetwork studies.

studyid is a variable identifying each study.

indepvars must be string for categorical variables and numeric for continuous variables. Depending on the design of the analysis,
there are required and optional covariates. The required covariates must be string variables. The required covariates are as follows;

The first covariate must be a binary variable in comparative analysis, and a multi-category variable (with at least 2 levels) in abnetwork meta-analysis.
In mcbnetwork or pcbnetwork studies, two first string covariates required are; index variable (multi-category; with at least 2 levels) and the comparator variable.

The variable names and the group names in the string variables should not contain underscores.

Description

metapreg is a routine for meta-analysis of proportions
from binomial data; the exact binomial distrubtion or a generalized linear model for the binomial family with a logit, loglog or the cloglog link is fitted.

The program fits fixed or a random-effects model. The data can be from independent studies; where each row contains data from seperate studies,
comparative studies; where each study has two rows of data. The first row has the index data and the second row has the control data. The data can also be matched,
where each row contains data from each seperate cross-tabulation between the index and the control test. When only the marginal data from the cross-tabulation is available,
then we refer this as paired data.

In abnetwork meta-analysis, each study contributes atleast two rows of data from different treatments/tests. In this setting we view the treatments assigned in a study as nested factors within a study.
The fitted models assumes exchangeability of the treatments effects and that the missing treatments are missing at random (MAR).

A random-effects model accounts for and allows the quantification of heterogeneity between (and within) studies while a fixed-effects model assumes homogeneity in studies.
By default, the exact binomial distribution is used when there are less than 3 studies.

In a comparative/mcbnetwork/pcbnetwork meta-analysis, the study-specific proportion ratios or odds ratios can be tabulated and/or plotted.

When there are no covariates, heterogeneity is also quantified using the I-squared measure(Zhou and Dendukuri 2014).
In abnetwork meta-analysis, we quantify the proportion of unexplained variation due to within and between study variability.

The command requires Stata 14.1 or later versions.

Model

model(metapreg##modeltype:type[, modelopts]) specifies the type of model to fit; default is model(random).
modelopts control the control the optimization process

link(logit|loglog|cloglog) specifies the function to transform the probabilities to a continuous scale that is unbounded. By default, the logit link is employed.

design(metapreg##designtype:design[, designopts]) specifies the type of the studies or design of meta-analysis; default is design(basic).
designopts are relevant in abnetwork and comparative meta-analysis.

nomc informs the program not to perform model comparison with likelihood-ratio tests comparison for the specified model with other simpler models

by(varname:byvar) specificies the stratifying variable for which the margins are estimated

interaction directs the model to include interaction terms between the first covariate and each of the remaining covariates

alphasort sort the categorical variables alphabetically

progress show the progress of the model estimation process

General

stratify requests for a consolidated sub-analyses by the by(varname:byvar) variable

dp(int:#) sets decimal points to display; default is dp(2)

level(level) sets confidence level; default is level(95)

power(int:#) sets the exponentiating power; default is power(0). # is any real value

sumstat(label) specifies the label(name) for proportions/relative ratios in the graph

sortby(varlist) requests to sort the data by variables in varlist

cimethod(metapreg##citype:icitype,ocitype) specifies how the confidence intervals
for the individuals(icytpe) studies or the overall(ociytpe) summaries are computed; default icytpe is cimethod(exact) for proportions and cimethod(koopman) for relative ratios

nooverall suppresses the overall estimate; by default the overall estimate is displayed

nosubgroup prevents the display of within-group summary estimates. By default both within-group and overall summaries are displayed

nowt suppresses the display of the weights from the tables and forest plots.

summaryonly requests to show only the summary estimates

outplot(metapreg##outplot:abs|rr|or) specifies to display/plot absolute/relative measures; default is outplot(abs)

download(path) specify the location where a copy of data used to plot the forest plot should be stored

smooth requests the study-specific smooth estimates

Table

noitable suppresses the table with the study-specific estimates

gof display the Akaike information and Bayesian information criterion

sumtable(metapreg##sumtable:none|logit|abs|rr|or|all) specifies to display the which tables to display logits,
proportions and/or the ratios of proportions or odds; by default all the summary tables are displayed

Forest plot

label(varname:[namevar=varname], [yearvar=varname]) specifies that date be labelled by its name and/or year

prediction compute and display the predictive intervals(proportions only)

nograph suppresses the forest plot; by default the forestplot is displayed

noovline suppresses the overall line; by default the overall line is displayed

nobox suppresses the display of weight boxes; by default the boxes are displayed

subline displays the group line; by default the group lines is not displayed

xlabel(list) defines x-axis labels. No checks are made as to whether these points are sensible.
So the user may define anything if the force option is used. The points in the list must be comma separated.

xtick(list) adds the listed tick marks to the x-axis. The points in the list must
be comma separated.

nostats suppresses the display of study specific proportions(or the relative ratios) and the confidence intervals

texts(#) indicates the text size of the labels and texts. Default is 1

lcols(varlist) specifies additional columns to the left of the plot

rcols(varlist) specifies additional columns to the right of the plot

astext(percentage) specifies the percentage of the graph to be taken up by text; default is astext(50)

double allows variables specified in lcols(varlist) and rcols(varlist) to run over two lines in the plot

diamopts(scatter##connect_options:connect_options) controls the diamonds

boxopts(scatter##marker_options:marker_options) controls the weight boxes

pointopts(scatter##marker_options:marker_options) controls the points for the study estimates

ciopts(scatter##connect_options:connect_options) controls the appearance of confidence intervals for studies

predciopts(scatter##connect_options:connect_options) controls the appearance of the prediction intervals for studies

olineopts(scatter##connect_options:connect_options) controls the overall and subgroup estimates line

logscale requests the plot to be in the (natural)log scale

twoway_options specifies other overall graph options

design

general notifies the program to perform a general/typical meta-analysis. The program expects atleast n N to be specified

comparative notifies the program that the data is from comparative studies. The program expects atleast n N bicat to be specified

pcbnetwork notifies the program that the data is from paired studies. The program expects atleast a b c d index comparator to be is supplied

mcbnetwork notifies the program that the data is from matched studies. The program expects atleast ab ac n index comparator to be is supplied

abnetwork instructs the program to perform abnetwork meta-analysis. The program expects atleast n N cat to be specified

model type

random|mixed fits a random-effects or mixed-effects logistic-normal model

fixed fits a fixed-effects logistic regression model

hexact uses the exact binomial distribution

citype

abs

exact computes exact confidence intervals; the default

wald computes Wald confidence intervals

wilson computes Wilson confidence intervals

agresti computes Agresti-Coull confidence intervals

jeffreys computes Jeffreys confidence intervals

rr

koopman computes Koopman asymptotic score confidence intervals; the default for comparative/paired studies. These intervals have better coverage even for small sample size

cml computes constrained maximum likelihood (cml) confidence intervals; the default for matched data. These intervals have better coverage even for small sample size

or

exact computes the exact CI of the study odds ratio by inverting two one-sided Fishers exact tests. These default intervals are overly convservative.

woolf use Woolf approximation to calculate CI of the study odds ratio.

cornfield use Cornfield approximation to calculate CI of the study odds ratio. These intervals have better coverage even for small sample size

sumtable

abs requests the display of the conditional and population-averaged proportions in a table

rr requests the display of the conditional and population-averaged risk ratios in a table

or requests the display of the conditional and population-averaged odds ratios in a table

logit requests the display of the conditional log-odds estimates of the fitted model in a table

none requests the suppression of the summary tables

outplot

abs requests the display of the study-specific and overall absolute measures in a table and /or a graph; the default

rr requests the display of the study-specific and summary risk ratios in a table and /or a graph. This is an option when studies are comparative, abnetwork or cbnetwork analysis

or requests the display of the study-specific and summary odds ratios in a table and /or a graph. This is an option when studies are comparative, abnetwork or cbnetwork analysis

Options

Design options

design(type, designopts) specifies the type of the studies or design of the meta-analysis to perform.
design is one of the following basic,
comparative, mcbnetwork, pcbnetwork and abnetwork. designopts specifies the options that give the user
more control parameterization of the comparative and abnetwork model.

design(basic) requests for a basic meta-analysis. The required varlist has the form n N.

design(comparative) indicates that the data is from comparative studies i.e there are two rows of data per each studyid. The required varlist has the form n N bicat
where bicat is the first covariate which should be a string variable with two levels. When there are two random effects in the model, their covariance structure can be
specified as independent with design(comparative,cov(independent)) or unstructured design(comparative,cov(unstructured))

design(mcbnetwork) indicates that the data is from matched studies and instructs to perform contrast-based network meta-analysis. There can be more than one row of data per each studyid. The required varlist has the form a b c d index comparator.
index comparator are the first two covariates and both should be string variables. index should have atleast two levels.
When there are matched observations from each study, the proportions are correlated.
The confidence intervals for the individual studies are computed accounting for this correlation.

design(pcbnetwork) indicates that the data is from paired studies and instructs to perform contrast-based network meta-analysis. There can be more than one row of data per each studyid. The required varlist has the form ab ac N index comparator.
index comparator are the first two covariates and both should be string variables. index should have atleast two levels.
pcbnetwork data is actually aggregated matched data where ab = a + b, ac = a + c and
n = a + b + c + d. Because the a b c d is not available, there is unfortunately no way to account
for the correlation when computing the confidence intervals for the individual studies.

design(abnetwork) instructs to perform arm-based network meta-analysis. The rquired varlist has the form n N cat where cat is the
first covariate which should be a string with atleast two levels.
There should be atleast two rows of data per studyid. baselevel(label) is relevant in abnetwork meta-analysis
and indicates the label of the reference level of the covariate of interest. The correct use is design(abnetwork, baselevel(label))

Model

model(type, modelopts) specifies the type of model to fit. type is either fixed, random, mixed or hexact.

model(hexact) uses the exact binomial distribution. The model assumes that the studies are homogeneous.

model(fixed) fits a fixed-effects logistic regression model to the data. The model assumes that the studies are homogeneous.

model(random) fits a random-effects (also called mixed-effects) model i.e. logistic-normal regression model be fitted to the data.

modelopts specifies the options that give the user
more control on the optimization process. The appropriate options
feed into the binreg(see maximize_options)
or meqrlogit (see maximize_options and
integration_options) or melogit (see maximize_options) for stata version 16 or higher.

The fixed-effects model is maximized using Stata's ml command. This implies that
irls is inadmissible option and ml is implicit.

Examples, model(random, intpoint(9)) to increase the integration points,
model(random, technique(bfgs)) to specify Stata's BFGS maximiztion algorithm.

link(link) specifies the function to transform the probabilities to a continuous scale that is unbounded. link is one of the following: logit, loglog and cloglog.

link(logit) is the default link function resulting to the logistic regression i.e. p = exp(xb)/(1 + exp(xb)).

link(loglog) request the use of the log-log link i.e. p = exp(-exp(xb)).

link(cloglog) request the use of the complementary log-log link i.e. p = 1 - exp(-exp(xb)).

The logit link is symmetric because the probabilities approach zero or one at the same rate.
The log-log and complementary log-log links are asymmetric. Complementary log-log link approaches zero slowly and one quickly. Log-log link approaches zero quickly and one slowly.
Either the log-log or complementary log-log link will tend to fit better than logistic and are frequently used when the probability of an event is small or large. The reason that logit is so prevalent is because logistic parameters can be interpreted as odds ratios.
When the complementary log-log model holds for the probability of a success, the log-log model holds for the probability
of a failure.

by(byvar) specifies that the summary etsimates be stratified/grouped according to the variable declared. This is useful in meta-regression with more than one covariate,
and the byvar is not one of the covariates or when there are interactions and the first covariate is not an ideal grouping variable. By default, results are grouped according to the
levels of the first categorical variable in the regression equation.

This option is not the same as the Stata by prefix which repeates the analysis for each group of observation for which the values of the prefixed variable are the same.

General

stratify requests for a consolidated sub-analyses by the by(varname:byvar) variable. The results are
presented in one table and one forest plot

dp(#) sets decimal points to display in the table and graph; default is dp(2)

level(level) sets confidence level for confidence and prediction intervals; default is level(95)

power(#) sets the exponentiating power with base 10; default is power(0). Any real value is allowed.
indicates the power of ten with which to multiply the estimates.
power(2) would report percentages.
The x-axis labels should be adjusted accordingly when power(#) is adjusted.

sumstat(label) specifies the label(name) for proportions/relative ratios in the forest plot and/or corresponding table

sortby(varlist) requests to sort the data by variables in varlist

cimethod(icitype, ocitype) specifies how the confidence intervals of the proportions are computed
for the individuals (icitype) studies or the summaries(ocitype) when the exact binomial distribution is used.

cimethod(exact) is the default for proportions and specifies exact/Clopper-Pearson binomial confidence intervals.
The intervals are based directly
on the binomial distribution unlike the Wilson score or Agresti-Coull. Their actual
coverage probability can be more than nomial value. This conservative nature
of the interval means that they are widest, especially with
small sample size and/or extreme probilities.

cimethod(wald) specifies the Wald confidence intervals.

cimethod(wilson) specifies Wilson confidence intervals.
Compared to the Wald confidence intervals, Wilson score intervals;
have the actual coverage probability close to the nominal value
and have good properties even with small sample size and/or extreme probilities.
However, the actual confidence level does not converge to the nominal level as n
increases.

cimethod(agresti) specifies the Agresti-Coull(Agresti, A., and Coull, B. A. 1998) confidence intervals
The intervals have better coverage with extreme probabilities
but slightly more conservation than the Wilson score intervals.

cimethod(jeffreys) specifies the Jeffreys confidence intervals

See Brown, Cai, and DasGupta (2001) and Newcombe (1998) for a discussion and
comparison of the different binomial confidence intervals.

With comparative and matched data, the Koopman scoreKoopman (1984)
and constrained maximum likelihood(cml)Nam, and Blackwelder (2002) confidence intervals for ratios are respectively computed.

nooverall suppresses the overall estimate; by default the overall estimate is displayed. This automatically
enforces the nowt option.

nowt suppresses the display of the weight

nosubgroup prevents the display of within-group summary estimates. By default both within-group and overall summaries are displayed

outplot(abs|rr|or) specifies to plot absolute/relative proportions; default is outplot(abs).

outplot(abs) is the default and specifies that the proportions be presented in the table and/or in the graph.

outplot(rr) requests that the proportion ratios be presented in the table and/or in the graph. This options is relevant with abnetwork, matched, pcbnetwork or comparative data.

outplot(or) requests that the odds ratios be presented in the table and/or in the graph. This options is relevant with abnetwork, matched, pcbnetwork or comparative data.

summaryonly requests to show only the summary estimates. Useful when there are many studies in the groups.

smooth requests for the model-based study-specific estimates.

Table

sumtable(none|logit|abs|rr|or|all) requests no summary table, summary log odds, summary proportions, summary proportion ratios, and summary odds ratios from the the fitted model be presented in a table.

sumtable(rr) requests that the summary proportion ratios be presented in the table. This options is whenever there are categorical covariates in the model.

sumtable(or) requests that the summary odds ratios be presented in the table. This options is whenever there are categorical covariates in the model.

gof display the goodfness of fit statistics; Akaike information and Bayesian information criterion.

Forest plot

prediction
displays the confidence interval of the approximate predictive
distribution of a future study, based on the extent of heterogeneity in the random-effects model.

Uncertainty on the spread of the random-
effects distribution using the formula t(N-k) x sqrt(se2 + tau2)
where t is the t-distribution with N-k degrees of freedom (N is the number of studies, k is the number of the model parameters), se2 is the
squared standard error and tau2 the heterogeneity statistic.
Note that with <3 studies the distribution is inestimable and effectively infinite, while heterogeneity is zero there is still
a slight extension as the t-statistic is always greater than the corresponding
normal deviate. For further information, see Higgins and Thompson 2001.

label([namevar=varname] [yearvar=varname])specifies that date be labelled by its name and/or year. Either or both variables
need not be specified. For the table display, the overall length of the
label is restricted to 20 characters. The lcols() option will override this when specified.

noovline suppresses the overall line; by default the overall line is displayed

subline displays the group line; by default the group lines is not displayed

xlabel(list) defines x-axis labels. No checks are made as to whether these points are sensible.
So the user may define anything if the force option is used. The points in the list must be comma separated.

xtick(list) adds the listed tick marks to the x-axis. The points in the list must
be comma separated.

nostats suppresses the display of study specific proportions(or the relative ratios) and the confidence intervals

nobox suppresses the display of weight boxes

texts(#) increases or decreases the text size of the
label by specifying # to be more or less than unity. The default is
usually satisfactory but may need to be adjusted.

lcols(varlist), rcols(varlist)
define columns of additional data to
the left or right of the plot. The first column on the right is
automatically set to the estimate, unless suppressed using
the options nostats. texts() can be used to fine-tune
the size of the text in order to achieve a satisfactory appearance.
The columns are labelled with the variable label, or the variable name
if this is not defined. The first variable specified in lcols() is assumed to be
the study identifier and this is used in the table output.

astext(percentage) specifies the percentage of the graph to be taken up by text;
default is astext(50). The percentage must be in the range 10-90.

double allows variables specified in lcols(varlist) and rcols(varlist) to
run over two lines in the plot. This may be of use if long strings are to be used.

diamopt(options) controls the appearance of the diamonds.
See connect_options for the relevant options. e.g diamopt(lcolor(red))
displays red red diamond(s).

boxopts(options) controls the weight boxes for the study estimates.
See marker_options for the relevant options. e.g boxopt(mcolor(green))

pointopt(options) controls the points for the study estimates.
See marker_options for the relevant options. e.g pointopt(msymbol(x) msize(0))

ciopt(options) ontrols the appearance of confidence intervals for studies.
See connect_options for the relevant options.

logscale requests the plot to be in the (natural)log scale

predciopt(options) controls the appearance of the prediction intervals for studies.
See connect_options for the relevant options.

olineopt(options) controls the overall and subgroup estimates line.
See connect_options for the relevant options.

twoway_options specifies overall graph options that would appear at the end of a
when all the different plots are combined together. This allows the addition of titles, subtitles, captions,
etc., control of margins, plot regions, graph size, aspect ratio, and the use of schemes.

Remarks

meqrlogit or melogit is used for the random-effects model and binreg for the fixed-effects model.
The binomial distribution is used to model the within-study variability (Hamza et al. 2008).
The weighting is implicit and proportional to the study size and within-study variance. The estimation of the model parameters is an iterative procedure.
The parameters are maximum likelihood estimates.

Examples

1.1 Intercept-only model and summary by triage group

The dataset used in examples 1.1-1.3 was used previously to produce Figure 1
in Marc Arbyn et al. (2009).

Intercept-only model and summary estimates grouped by triage group,
with specified x-axis label, e.t.c.

. use http://fmwww.bc.edu/repec/bocode/a/arbyn2009jcellmolmedfig1.dta

. decode tgroup, g(STRtgroup)

. #delimit ;

. metapreg num denom,

studyid(study)

by(STRtgroup)

cimethod(exact)

label(namevar=author, yearvar=year)

xlab(.25, 0.5, .75, 1)

subti(Atypical cervical cytology, size(4))

graphregion(color(white))

texts(1.5) smooth gof;

. #delimit cr

(click to run)

1.2 Seperate intercept-only model by triage group

With the by(STRtgroup) option in Example1.1 the estimates in each group are similar.
To obtain seperate tables and graphs, use instead the by prefix instead i.e bysort tgroup:
or by tgroup: if tgroup is already sorted. The option rc0 ensures that the program runs in all groups even when there could
be errors encountered in one of the sub-group analysis. Without the option, the program stops running when the
first error occurs in one of the groups.

Fitting logistic regression for each category in triage group,
with specified x-axis label, Wilson confidence intervals for the studies, e.t.c.

. use http://fmwww.bc.edu/repec/bocode/a/arbyn2009jcellmolmedfig1.dta

. #delimit ;

. bys tgroup, rc0: metapreg num denom,

studyid(study)

cimethod(wilson)

label(namevar=author, yearvar=year)

xlab(.25, 0.5, .75, 1)

graphregion(color(white))

subti(Atypical cervical cytology, size(4))

texts(1.5) smooth;

. #delimit cr

(click to run)

1.3 Meta-regression with tgroup as a covariate

The use of by(tgroup) in Example1.1 only allows informal testing of heterogeneity between the sub-groups.
The formal testing is perfomed by fitting a logistic regression with triage used as a categorical variable and entered in string format.
Since tgroup is a factor variable, the decode function creates the new string variable based on the existing numerical variable and its value labels.

Triage group as a covariate, display all summary tables, e.t.c.

. use http://fmwww.bc.edu/repec/bocode/a/arbyn2009jcellmolmedfig1.dta

. decode tgroup, g(STRtgroup)

. metapreg num denom STRtgroup, ///

studyid(study) ///

sumtable(all) ///

cimethod(exact) ///

label(namevar=author, yearvar=year) ///

xlab(.25,0.5,.75,1) ///

subti(Atypical cervical cytology, size(4)) ///

graphregion(color(white)) ///

texts(1.5) summaryonly

(click to run)

2.1 Proportions near 0 - Intercept-only model - Logit link

Logistic regression correctly handles the extreme cases appropriately without need for transformation. Options for the forest plot; specified x-axis label, ticks on x-axis added,
suppressed weights, increased text size, a black diamond for the confidence intervals of the pooled estimate, a black vertical line at zero, a red dashed line, for the pooled estimate, e.t.c.

The dataset used in this example produced the top-left graph in figure two in
Ioanna Tsoumpou et al. (2009).

. use http://fmwww.bc.edu/repec/bocode/t/tsoumpou2009cancertreatrevfig2WNL.dta

.	metapreg p16p p16tot, ///

studyid(study) ///

label(namevar=author, yearvar=year) ///

sortby(year author) ///

xlab(0, .2, 0.4, 0.6, 0.8, 1) ///

xline(0, lcolor(black)) ///

ti(Positivity of p16 immunostaining, size(4) color(blue)) ///

subti("Cytology = WNL", size(4) color(blue)) ///

pointopt(msymbol(X) msize(2)) ///

graphregion(color(white)) ///

texts(1.5) smooth gof

(click to run)

2.2 Proportions near 0 - Intercept-only model - loglog link

The loglog regression is an extension of the logistic regression model and is particularly useful when the probability of an event is very small.

. use http://fmwww.bc.edu/repec/bocode/t/tsoumpou2009cancertreatrevfig2WNL.dta

.	metapreg p16p p16tot, link(loglog) ///

studyid(study) ///

label(namevar=author, yearvar=year) ///

sortby(year author) ///

xlab(0, .2, 0.4, 0.6, 0.8, 1) ///

xline(0, lcolor(black)) ///

ti(Positivity of p16 immunostaining, size(4) color(blue)) ///

subti("Cytology = WNL", size(4) color(blue)) ///

pointopt(msymbol(X) msize(2)) ///

graphregion(color(white)) ///

texts(1.5) smooth gof

(click to run)

3.1 Risk-ratios: Comparative studies

The data used in examples 3.1-3.3 are as presented in table IV of Berkey et al. (1995)
By supplying the risk-ratios and their variability, Sharp (1998) Sharp demonstrates meta-analysis of odds-ratios with the meta command. He fitted a random and a fixed effects model to the data.

The logistic regression model appropriately accounts for both within- and between-study heterogeneity, with vaccination arm as a covariate.
The options comparative indicates that the data is comparative. The first covariate bcg, identifies the first and the second observations of the pair.
The risk-ratios are requested with the option outplot(rr). All output tables are requested with the option sumtable(all).

//fmwww.bc.edu/repec/bocode/b/bcg.dta""':. use "http://fmwww.bc.edu/repec/bocode/b/bcg.dta"

.metapreg cases_tb population bcg, ///

studyid(study) ///

sumtable(all) ///

design(comparative)	///

outplot(rr) ///

sumstat(Risk ratio) ///

graphregion(color(white)) ///

xlab(0, 1, 2) ///

xtick(0, 1, 2) ///

logscale smooth ///

xtitle(Relative Ratio,size(2)) ///

rcols(cases_tb population) ///

astext(80) ///

texts(1.5)

(click to run)

3.2 Continous covariate

We investigate whether altitude has an effect on the vaccination by including alt as a continous covariate.

//fmwww.bc.edu/repec/bocode/b/bcg.dta""':. use "http://fmwww.bc.edu/repec/bocode/b/bcg.dta"

.metapreg cases_tb population lat, ///

studyid(study) ///

sumtable(all) by(bcg) ///

sortby(lat) ///

sumstat(Proportion) ///

graphregion(color(white)) ///

xlab(0, 0.05, 0.1) ///

xtick(0, 0.05, 0.1) ///

rcols(cases_tb population) ///

astext(80) ///

texts(1.5) smooth

(click to run)

3.3 Risk-ratios: Comparative studies and a continous covariate

With metareg, Sharp (1998) investigaged the effect of latitude on BCG vaccination.
The analysis suggested that BCG vaccination was more effective at higher absolute latitude.

We now fit a logistic regression model with bcg, a categorical variable for the arm and lat, a continous variable with absolute latitude.

Activated by the option interaction, an interaction term allows to assess whether the log OR for arm vary by absolute latitude.

The interaction term from metapreg and the coefficient for lat using metareg as was done by Sharp (1998) are equivalent.

//fmwww.bc.edu/repec/bocode/b/bcg.dta""':. use "http://fmwww.bc.edu/repec/bocode/b/bcg.dta"

. metapreg cases_tb population bcg lat, ///

studyid(study) ///

sortby(lat) ///

sumtable(all) ///

design(comparative) ///

outplot(rr) ///

interaction ///

graphregion(color(white)) ///

xlab(0, 1, 2) ///

xtick(0, 1, 2) ///

rcols(cases_tb population) ///

astext(80) ///

texts(1.5) logscale smooth

(click to run)

4.1 Meta-regression - Comparative studies - Sparse data

Using metan, Chaimani et al. (2014) informaly assessed the difference in treatment effect of haloperidol compared to placebo in treating schizophrenia.

The analysis is more appropriately perfomed using metapreg by including arm and missingdata as covariates.

The interaction term allows to test whether the risk-ratios for arm differ between the group with and without missing data.

//fmwww.bc.edu/repec/bocode/s/schizo.dta""':. use "http://fmwww.bc.edu/repec/bocode/s/schizo.dta"

. sort firstauthor arm

. metapreg response total arm missingdata, ///

studyid(firstauthor) link(loglog) ///

sortby(year) ///

sumtable(all) ///

design(comparative) ///

outplot(rr) ///

interaction ///

graphregion(color(white)) ///

xlab(0, 5, 15) ///

xtick(0, 5, 15) ///

sumstat(Rel Ratio) ///

lcols(response total year) ///

astext(70) ///

texts(1.5) logscale smooth

(click to run)

5.1 Meta-regression - matched Studies - sparse data

We demonstrate the use of mcbnetwork option when matched data is available. The data should be a from a 2x2 table as displayed below;

| comparator

index | Positive Negative | Total

- - - - - - - - - - - - - - - - - -

Positive| a b | a + b

Negative| c d | c + d

- - - - - - - - - - - - - - - - - -

Total | a + c b + d | a + b + c+ d

//fmwww.bc.edu/repec/bocode/m/matched.dta""':. use "http://fmwww.bc.edu/repec/bocode/m/matched.dta"

. metapreg a b c d index comparator, ///

studyid(study) ///

model(fixed) sumtable(all) ///

design(mcbnetwork) ///

by(comparator) ///

graphregion(color(white)) ///

xlab(0.9, 1, 1.1) xtick(0.9, 1, 1.1) ///

sumstat(Ratio) ///

lcols(comparator index) ///

astext(80) texts(1.2) logscale smooth

(click to run)

Stored results

metapreg stores the following in e():

Matrices

e(rrout) summary relative ratios when there categorical covariates

e(poprrout) population-averaged summary relative ratios when there categorical covariates

e(orout) summary odds ratios when there categorical covariates

e(poporout) population-averaged summary odds ratios when there categorical covariates

e(absout) summary proportions

e(popabsout) population-averaged summary proportions

e(hetout) heterogeneity test statistics after a fitting a random-effects model

e(absoutp) summary proportions predictive intervals

e(logodds) summary log-odds

e(mctest) model compariston statistics after meta-regression

e(nltest) hypothesis test statistics for equality of relative ratio

Available model estimates:

metapreg_modest estimates from the fitted model

Technical note

When prefix by is used, only the results from the last group or the first model will be stored respectively.

Author

Victoria N. Nyaga (Victoria.NyawiraNyaga@sciensano.be)

Belgian Cancer Center/Unit of Cancer Epidemiology,

Sciensano,

Juliette Wytsmanstraat 14,

B1050 Brussels,

Belgium.

References

Agresti, A., and Coull, B. A. 1998. Approximate is better than 'exact'
for interval estimation of binomial proportions. The American Statistician.
52:119-126.

Zhou, Y., and Dendukuri, N. 2014. Statistics for quantifying heterogeneity in univariate
and bivariate meta-analyses of binary data: The case of meta-analyses of diagnostic accuracy.
Statistics in Medicine 33(16):2701-2717.

Brown, L. D., T. T. Cai, and A. DasGupta. 2001.
Interval estimation for a binomial proportion.
Statistical Science 16: 101-133.

Clopper, C. J., and E. S. Pearson. 1934. The
use of confidence or fiducial limits illustrated in the case of the binomial.
Biometrika 26: 404-413.

Hamza et al. 2008. The binomial distribution of meta-analysis was preferred to model within-study variability.
Journal of Clinical Epidemiology 61: 41-51.

Higgins, J. P. T., and S. G. Thompson. 2001. Presenting random-effects
meta-analyses: Where we are going wrong? 9th International Cochrane
Colloquium, Lyon, France.

DerSimonian, R. and Laird, N. 1986. Meta-analysis in clinical trials. Controlled Clinical Trials 7(3):177-188.

Newcombe, R. G. 1998. Two-sided confidence intervals for
the single proportion: comparison of seven models.
Statistics in Medicine 17: 857-872.

Pavlou M. et. al. 2015.
A note on obtaining correct marginal predictions from a random intercepts model for binary outcomes.
BMC Medical Research modelology 15(1):1-6

Arbyn, M., et al. 2009. Triage of women with equivocal
or low-grade cervical cytology results. A meta-analysis
of the HPV test positivity rate.
Journal for Cellular and Molecular Medicine 13(4):648-59.

Tsoumpou, I., et al. 2009. p16INK4a immunostaining in
cytological and histological specimens from the uterine
cervix: a systematic review and meta-analysis.
Cancer Treatment Reviews 35: 210-20.

Stephen Sharp. 1998. sbe23. Meta-analysis regression.
Stata Technical Bulletin 16-22.

Berkey, C., et al. 1995. A random-effects regression model for meta-analysis.
Statistics in Medicine 14:395-411.

Chaimani, A., Mavridis, D., & Salanti G. 2014. A hands-on practical tutorial on perfoming meta-analysis with Stata.
Evidence Based Mental Health 17(4):111-116.

Koopman, P. 1984. Confidence Intervals for the Ratio of Two Binomial Proportions.
Biometrics 40(2):513.

Nam, J. & Blackwelder, W. 2002. Analysis of the ratio of marginal probabilities in a matched-pair setting.
Statistics in Medicine 21(5):689-699.