Beruflich Dokumente
Kultur Dokumente
Metan
metan varlist [if] [in] [weight] [, measure_and_model_options
options_for_continuous_data output_options forest_plot_options ]
labbe varlist [if exp] [in range] [weight] [, nowt percent or(#)
rr(#) rd(#) null logit wgt(weightvar) symbol(symbolstyle)
nolegend id(idvar) textsize(#) clockvar(clockvar) gap(#)
graph_options
Description
metan (the main meta-analysis routine) requires either two, three, four,
or six variables to be declared. When four variables are specified these
correspond to the number of events and nonevents in the experimental
group followed by those of the control group, and analysis of binary data
is performed on the 2 x 2 table. With six variables, the data are
assumed continuous and to be the sample size, mean, and standard
deviation (SD) of the experimental group followed by those of the control
group. If three variables are specified, these are assumed to be the
effect estimate and its lower and upper confidence interval, and it is
suggested that these are log transformed for odds ratios or risk ratios
and the eform option used. If two variables are specified, these are
assumed to be the effect estimate and standard error; again, it is
recommended that odds ratios or risk ratios are log transformed.
labbe draws a L'Abbe plot for event data (proportion of successes in the
two groups). This is an alternative to the graph produced by metan8.
Note that the metan command now requires Stata 9 and has been updated
with several new options. Changes are mainly to graphics options that are
discussed in the section Further options in the v9 update for metan:
Forest plot, or otherwise marked v9 update. The previous version is still
available under the name metan7.
The metafunnel command has more options for funnel plots and version 8
graphics; as such funnel has been removed. See metafunnel (if installed)
+----------------------------------+
----+ Specifying the measure and model +---------------------------------
fixed specifies a fixed effect model using the method of Mantel and
Haenszel (the default).
fixedi specifies a fixed effect model using the inverse variance method.
random specifies a random effects model using the method of DerSimonian &
Laird, with the estimate of heterogeneity being taken from the from
the Mantel-Haenszel model.
The results of this analysis are then displayed in the table and
forest plot. Note that if by is used then sub-estimates from the
second method are not displayed with user defined estimates, for
obvious reasons.
+-----------------+
----+ Continuous data +--------------------------------------------------
nointeger denotes that the number of observations in each arm does not
need to be an integer. By default, the first and fourth variables
specified (containing N_intervention and N_control respectively) may
occasionally be noninteger (see entry for nointeger under binary
data).
+--------+
----+ Output +-----------------------------------------------------------
log reports the results on the log scale (valid for OR and RR analyses
from raw data counts only).
5
eform exponentiates all effect sizes and confidence intervals (valid only
when the input variables are log odds-ratios or log hazard-ratios
with standard error or confidence intervals).
ilevel(#) specifies the coverage (e.g., 90, 95, 99 percent) for the
individual trial confidence intervals. The default is $S_level.
ilevel() and olevel() need not be the same. See set level.
olevel(#) specifies the coverage (e.g., 90, 95, 99 percent) for the
overall (pooled) trial confidence intervals. The default is $S_level.
ilevel() and olevel() need not be the same. See set level.
+-------------+
----+ Forest plot +------------------------------------------------------
effect(string) may be used when the effect size and its standard error
are declared. This allows the graph to name the summary statistic
used.
counts (v9 update) displays data counts (n/N) for each group when using
binary data, or the sample size, mean, and SD for each group if mean
differences are used (the latter is a new feature).
xlabel() (v9 update) defines x-axis labels. This has been modified so
that any number of points may defined. Also, there are no longer any
checks made as to whether these points are sensible, so the user may
define anything if the force option is used. Points must be comma
separated.
xtick() adds tick marks to the x axis. Points must be comma separated.
boxsca() (v9 update) controls box scaling. This has been modified
slightly so that the default is 100 (as in a percentage) and may be
increased or decreased as such (e.g., 80 or 120 for 20% smaller or
larger respectively)
nobox prevents a "weighted box" being drawn for each study and markers
for point estimates only are shown.
texts() (v9 update) specifies font size for text display on graph. This
has been modified slightly so that the default is 100 (as in a
percentage) and may be increased or decreased as such (e.g., 80 or
120 for 20% smaller or larger, respectively)
+------------------------------------------------------+
----+ Further options for the forest plot in the v9 update +-------------
double allows variables specified in lcols and rcols to run over two
7
lines in the plot. This may be of use if long strings are to be used.
summaryonly shows only summary estimates in the graph (may be of use for
multiple subgroup analyses)
rflevel(#) specifies the coverage (e.g., 90, 95, 99 percent) for the
confidence interval of the predictive distribution. The default is
$S_level. See set level.
boxopt() controls the boxes and uses options for a weighted marker
8
diamopt() controls the diamonds and uses options for pcspike (not
horizontal/vertical). See line_options.
classic specifies that solid black boxes without point estimate markers
are used as in the previous version of metan.
nowarning switches off the default display of a note warning that studies
are weighted from random-effects anaylses.
nowt declares that the plotted data points are to be the same size.
rr(#) draws a line corresponding to a fixed risk ratio of #. See also the
rrn() option.
logit is for use with the or() option; it displays the probabilities on
the logit scale ie log(p/1-p). On the logit scale, the odds ratio is
a linear effect, and so this makes it easier to assess the "fit" of
the line.
gap(#) increases or decreases the gap between the study marker and the ID
label by specifying # to be more or less than unity. The default is
usually satisfactory but may need to be adjusted.
Remarks on metan
The eform option may be used to change back to the original scale if
needed. By default the confidence intervals are assumed symmetric, and
the studies are pooled by taking the variance to be equal to (CI
width)/2z.
Note that for graphs on the log scale (that is, ORs or RRs), values
outside the range [10e-8,10e8] are not displayed, and similarly graphs of
other measures (log ORs, RDs, SMDs) are restricted to the range
[-10e8,10e8]. A confidence interval which extends beyond this, or the
specified scale if force is used, will have an arrow added at the end of
the range.
Remarks on labbe
Stored
Examples
. use http://fmwww.bc.edu/repec/bocode/m/metan_example_data
Risk difference from raw cell counts, random effects model, "label"
specification with counts displayed
Sort by year, use data columns syntax. Text size increased, specify
percentage of graph as text and two lines per study; suppress stats,
weight, heterogeneity stats and table.
Generate log odds ratio and standard error, analyse with 2 parameter
syntax. Graph has exponential form, scale is forced within set
limits and ticks added, effect label specified.
xlabel(0,10,20,30,40,50,60,70,80,90,100) force
null(50) label(namevar=id) nooverall notable
title(Sensitivity, position(6))
(click to run)
User has analysed data with a nonstandard technique and supplied effect
estimates, weights and description of statistics. The scheme
"Economist" has been used.
Variable counts defined showing raw data. Options to change the box,
effect estimate marker and confidence interval used, and the counts
variable has been attached to the estimate marker as a label.
L'Abbe plot with labelled axes and display of risk ratio and risk
difference.
Authors
Version 9 update
13
Patrick Royston. MRC Clinical Trials Unit, 222 Euston Road, London, NW1 2DA
Acknowledgements
Thanks to Vince Wiggins, Kit Baum, and Jeff Pitblado of Statacorp who
offered advice and helped facilitate the version 9 update. Thanks also
to all the people who helped with beta-testing and made comments and
suggested improvements.
References
Also see
binary_data_options
continuous_data_options
precalculated_effect_estimates_options
fixed random
measure_and_model_option
wgt(wgtvar)
output_options
forest_plot_options
Description
This updated version requires that metan is installed, for which metacum
15
now acts as a wrapper. As such the syntax is very similar, allowing the
user to supply data in a variety of formats. Version 9 graphics are
displayed and most of the options for metan, and many general graphics
options, are permitted. This help file is very similar to that of metan,
although with the omission of some options.
Options
- binary_data_options
or pools ORs.
observations.
- continuous_data_options
nointeger denotes that the number of observations in each arm does not
need to be an integer. By default, the first and fourth variables
specified (containing N_intervention and N_control, respectively) may
occasionally be noninteger (see nointeger under binary data).
- precalculated_effect_estimates_options
- measure_and_model_option
wgt(wgtvar) specifies alternative weighting for any data type. The effect
size is to be computed by assigning a weight of wgtvar to the
studies. When RRs or ORs are declared, their logarithms are weighted.
This option should be used only if you are satisfied that the weights
are meaningful.
- output_options
log reports the results on the log scale (valid only for ORs and RRs
analyses from raw data counts).
eform exponentiates all effect sizes and confidence intervals (valid only
when the input variables are log-ORs or log-hazard ratios with
standard error or confidence intervals).
ilevel(#) specifies the coverage (e.g., 90%, 95%, 99%) for the individual
trial confidence intervals; the default is $S_level. See set level.
- forest_plot_options
textsize(#) specifies the font size for the text display on the graph.
This option has been modified so that the default is textsize(100)
(as in 100%) and the percentage may be increased or decreased (e.g.,
80 or 120 for 20% smaller or larger, respectively).
counts displays data counts (n/N) for each group when using binary data
or the sample size, mean, and standard deviation for each group if
mean differences are used (the latter is a new feature).
group1(string) and group2(string) may be used with the counts option, and
the text should contain the names of the two groups.
18
effect(string) allows the graph to name the summary statistic used when
the effect size and its standard error are declared.
double allows variables specified in lcols() and rcols() to run over two
lines in the plot. This option may be of use if long strings are
used.
summaryonly shows only summary estimates in the graph. This option may be
of use for multiple subgroup analyses.
classic specifies that solid black boxes without point estimate markers
are used, as in the previous version of metan.
nowarning switches off the default display of a note warning that studies
are weighted from random-effects analyses.
Note that for graphs on the log scale (that is, ORs or RRs), values
outside the range [10e-8,10e8] are not displayed, and similarly graphs of
other measures (log ORs, RDs, SMDs) are restricted to the range
[-10e8,10e8]. A confidence interval which extends beyond this, or the
specified scale if force is used, will have an arrow added at the end of
the range.
Examples
. use http://fmwww.bc.edu/repec/bocode/m/metan_example_data
Risk difference from raw cell counts, random effects model, "label"
specification
20
Generate log odds ratio and standard error. Graph has exponential form,
scale is forced within set limits and ticks added. Data columns
syntax used and effect label specified.
Reference
Authors
First version
Jonathan A. C. Sterne
Department of Social Medicine, University of Bristol, Canynge Hall,
Whiteladies Road, Bristol BS8 2PR, UK
Version 9 update
Ross J. Harris
Department of Social Medicine, University of Bristol, Canynge Hall,
Whiteladies Road, Bristol BS8 2PR, UK
Also see
Online: metan, metannt (if installed), meta (if installed), metareg (if
installed), metabias (if installed), metatrim (if installed),
metainf (if installed), galbr (if installed), metafunnel (if
installed)
21
Syntax
Description
Options
graph requests a line graph of fitted values plotted against the first
covariate in indepvars, together with the estimates from each study
represented by circles. By default, the circle sizes depend on the
precision of each estimate (the inverse of its within-study
variance), which is the weight given to each study in the
fixed-effects model.
randomsize is for use with the graph option. It specifies that the size
22
The mm, reml, and eb options are alternatives that specify the method of
estimation of the additive (between-study) component of variance tau2.
z requests that the knapphartung modification not be applied and that the
standard normal distribution be used to calculate p-values and
confidence intervals. This is the default when the permute() option
is specified with a fixed-effects model.
tau2test adds to the output two tests of tau2 = 0. The first is based on
the residual heterogeneity statistic, Q_res. The second (not
available if the mm option is also specified) is a likelihood-ratio
test based on the REML log likelihood. These are two tests of the
same null hypothesis (the fixed-effects model with tau2 = 0), but the
alternative hypotheses are different, as are the distributions of the
test statistics under the null, so close agreement of the two tests
is not guaranteed. Both tests are typically of little interest
because it is more helpful to quantify heterogeneity than to test for
23
it.
log requests the display of the iteration log during estimation of tau2.
This is ignored if the mm option is specified, because this uses a
noniterative method.
The eform, level(), and z options have no effect when the permute()
option is specified.
24
Syntax of predict
where statistic is
These statistics are available both in and out of sample; type predict
... if e(sample) ... if wanted only for the estimation sample.
xb, the default, calculates the linear prediction, x_i*b, that is, the
fitted values excluding the random effects.
stdp calculates the standard error of the prediction (the standard error
of the fitted values excluding the random effects).
stdf calculates the standard error of the forecast. This gives the
standard deviation of the predicted distribution of the true value of
depvar in a future study, with the covariates given by varlist.
stdf^2 = stdp^2 + tau2.
u calculates the predicted random effects, u_i. These are the best
linear unbiased predictions of the random effects, also known as the
empirical Bayes (or posterior mean) estimates of the random effects,
or as shrunken residuals.
effects.
hat calculates the leverages (the diagonal elements of the projection hat
matrix).
Saved results
When the permute() option is not specified, metareg saves the following
in e():
Scalars
e(N) number of observations
e(df_m) model degrees of freedom
e(df_Q) degrees of freedom for test of Q=0
e(df_r) residual degrees of freedom (if t tests used)
e(remll) REML log likelihood
e(chi2_c) chi^2 for comparison test
e(F) model F statistic
e(tau2) estimate of tau2
e(Q) Cochran's Q
e(I2) I-squared
e(q_KH) Knapp-Hartung variance modification factor
e(remll_c) REML log likelihood, comparison model
e(tau2_0) tau2, constant-only model
e(chi2) model chi^2
Macros
e(cmd) metareg
e(predict) program used to implement predict
e(wsse) name of wsse() variable
e(depvar) name of dependent variable
e(method) REML, Method of moments, or Empirical Bayes
e(properties) bV
Matrices
e(b) coefficient vector
e(V) variance-covariance matrix of estimators
Functions
e(sample) marks estimation sample
Examples
Note
References
Knapp, G., and J. Hartung. 2003. Improved tests for a random effects
meta-regression with a single covariate. Statistics in Medicine 22:
2693-2710.
Author
Roger M. Harbord
Department of Social Medicine
University of Bristol, UK
roger.harbord@bristol.ac.uk
Acknowledgments
27
Also see
Online: [R] vwls, [R] permute, meta (if installed), metan (if
installed), meta_dialog (if installed)
28
metafunnel
Funnel plots for meta-analysis
Description
The syntax is based on the same framework as for the meta, metabias,
metacum, and metatrim commands. The user provides the effect estimate
theta and either its standard error, se, or its variance, var.
Alternatively, the user may provide exp(theta), its confidence interval
(ll, ul), and, optionally, the confidence level. For more details, see
help meta.
Options
var and ci indicate that instead of the standard error of theta, the user
supplied the variance of theta or confidence interval for exp(theta).
For more details, see help meta.
reverse inverts the funnel plot so that larger studies are displayed at
the bottom of the plot with smaller studies at the top. This may
also be achieved by specifying noreverse as part of the
yscale(axis_description) graphics option.
egger adds the fitted line corresponding to the regression test for
funnel-plot asymmetry proposed by Egger et al. (1997) and implemented
in metabias. This option may not be combined with the by() option.
Remarks
The funnel plots are displayed in line with meta-analytic convention and
the recommendations of Sterne and Egger (2001). The effect of the
treatment or intervention in each study:
Users who wish to plot the treatment effect on the vertical axis should
use the graph(begg) option of the metabias command. The funnel command,
which is part of the metan package, also provides an alternative way to
draw funnel plots.
The plots include pseudo-95% confidence interval lines, which are drawn
around the summary fixed-effect estimate of the intervention or treatment
effect. The lines may be omitted using the nolines option. The user may
also specify that the pseudo confidence limits are centered around a zero
intervention effect using the forcenull option.
When the eform option is used, the label of the horizontal axis
(treatment effect, theta) is changed accordingly, unless there is a
variable label for theta or the xtitle(axis_title) graphics option is
used.
By default, the subtitle "Funnel plot with pseudo 95% confidence limits"
is displayed (or simply "Funnel plot" if the nolines option is
specified). This may be changed using the graphics option
subtitle(tinfo).
Examples
Acknowledgments
References
31
Also see
Online: help for meta, metabias, metainf, metatrim, metan, funnel (if
installed)
32
confunnel
Realce en el gráfico en embudo de los contornos de significación estadística
Syntax
options description
-------------------------------------------------------------------------
contours(numlist) specify significance levels of the
contours to be plotted; default is
1%, 5%, and 10% significance levels
contcolor(colorstyle) specify color of the contour lines
if shadedcontours is not specified
extraplot(plots) specify additional plots to overlay
the funnel plot
functionlowopts(options) pass options to the twoway function
commands used to draw the contours
functionuppopts(options) pass options to the twoway function
commands used to draw the contours
legendlabels(labels) specify labels in the legend for
added items
legendopts(options) specify options that affect the plot
legend
metric(se|invse|var|invvar) the scale of the y axis; either se,
invse, var, or invvar
onesided(lower|upper) lower- or upper-tailed, one-sided
significance contours
scatteropts(options) specifies any of the options
documented in scatter
shadedcontours specify shaded, instead of black,
contour lines
[no]shadedregions specify or suppress shaded regions
between the contours
solidcontours specify solid, instead of dashed,
contour lines
studylab(string) the legend label for the scatter
points
twowayopts(twoway_options) pass options to the twoway plot
twoway_options pass options to the twoway plot
-------------------------------------------------------------------------
Description
Options
noshadedregions option.
Remarks
Examples
References
Sterne, J. A. C., and M. Egger. 2001. Funnel plots for detecting bias in
meta-analysis: Guidelines on choice of axis. Journal of Clinical
Epidemiology 54: 1046-1055.
Author
Also see
metabias
Syntax
metabias varlist [if] [in], egger harbord peters begg [graph nofit or
rr level(#) graph_options]
Description
Options
egger, harbord, peters, and begg specify that the original Egger test,
Harbord's modified test, Peters' test, or the rank correlation test
proposed by Begg and Mazumdar (1994) be reported, respectively.
There is no default; one test must be chosen.
or (the default for binary data) uses odds ratios as the effect estimate
of interest.
rr specifies that risk ratios rather than odds ratios be used. This
option is not available for the Peters test.
Examples
Authors
Reference
The dialog box added to sbe19.5 (and to the distribution dated 20040409
on SSC) is not compatible with this revised and extended version of the
package, which does not currently include a dialog box.
Also see
glst
Generalized Least Squares for Trend… para estudios de tendencias de análisis de dosis-
respuesta
Syntax
glst depvar dose [indepvars] [if] [in], se(varname) cov(n cases) {cc
| ir | ci} [options]
options description
-------------------------------------------------------------------------
* se(varname) variable containing estimate of standard error
* cov(n cases) variables containing the information required to fit
the covariances
+ cc case-control data
+ ir incidence-rate data
+ ci cumulative incidence data
vwls variance-weighted least-squares estimation
crudes crude relative risks and correlations
pfirst(id study) pool-first method
Description
Options
crudes specifies to calculate the vector of crude relative risks, and its
variance-covariance and correlation matrices. This option also
provides the relative differences (as percentages) between crude and
adjusted relative risks and their correlation matrix.
predictor.
Example
Input data from table 1, page 1302 of Greenland and Longnecker (1992)
Reference
Authors
Support
http://nicolaorsini.altervista.org
nicola.orsini@ki.se
Also see