-
Notifications
You must be signed in to change notification settings - Fork 1
/
ivmsmm.sthlp
201 lines (160 loc) · 6.68 KB
/
ivmsmm.sthlp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
{smcl}
{* *! version 0.1.0 03sep2021 Tom Palmer}{...}
{vieweralsosee "ivonesamplemr" "help ivonesamplemr"}{...}
{vieweralsosee "ivpoisson" "help ivpoisson"}{...}
{vieweralsosee "ivpois" "help ivpois"}{...}
{viewerjumpto "Syntax" "ivmsmm##syntax"}{...}
{viewerjumpto "Description" "ivmsmm##description"}{...}
{viewerjumpto "Options" "ivmsmm##options"}{...}
{viewerjumpto "Examples" "ivmsmm##examples"}{...}
{viewerjumpto "Stored results" "ivmsmm##results"}{...}
{viewerjumpto "References" "ivmsmm##references"}{...}
{viewerjumpto "Author" "ivmsmm##author"}{...}
{title:Title}
{p 5}
{bf:ivmsmm} {hline 2} Multiplicative structural mean model
{p_end}
{marker syntax}{...}
{title:Syntax}
{p 8 14 2}
{cmd:ivmsmm} {depvar} [{it:{help varlist:varlist1}}]
{cmd:(}{it:{help varlist:varlist2}} {cmd:=}
{it:{help varlist:varlist_iv}}{cmd:)} {ifin}
[{it:{help ivpoisson##weight:weight}}]
[{cmd:,} {it:log} {it:noirr} {it:ivpoisson_options}]
{phang}
{it:varlist1} is the list of exogenous variables.{p_end}
{phang}
{it:varlist2} is the list of endogenous variables.{p_end}
{phang}
{it:varlist_iv} is the list of exogenous variables used with {it:varlist1}
as instruments for {it:varlist2}.
{synoptset 20 tabbed}{...}
{synopthdr}
{synoptline}
{synopt:{opt noirr:}}Do not display exponentiated estimates{p_end}
{synopt:{opt log:}}Show the GMM iteration log{p_end}
{synopt:{opt ivpoisson_options:}}{help ivpoisson##optionstbl}{p_end}
{marker description}{...}
{title:Description}
{pstd}
{cmd:ivmsmm} implements the multiplicative structural mean model (MSMM) of {help ivmsmm##robins:Robins (1989)}
as a wrapper to {help ivpoisson} with the {cmd:multiplicative} option.
{cmd:ivpoisson} performs generalized method of moments (GMM) estimation of the relevant moment
condition using {help gmm}.
{pstd}
The equivalence of the models of {help ivmsmm##robins:Robins (1989)} and
{help ivmsmm##mullahy:Mullahy (1997)}, which was implemented in {help ivpois},
{help ivmsmm##nichols:Nichols (2007)}
and {help ivpoisson} with the {cmd:mult} option, and discussed in detail by
{help ivmsmm##windmeijer-1:Windmeijer and Santos Silva (1997)} and
{help ivmsmm##windmeijer-2:Windmeijer (2002)}, was shown by
{help ivmsmm##palmer-2011:Palmer (2011)}. These models produce moment
conditions equivalent to gamma regression
{help ivmsmm##dukes:Dukes and Vansteelandt (2018)}.
{marker options}{...}
{title:Options}
{phang}
Please see {help ivpoisson##options}
{marker examples}{...}
{title:Examples}
{pstd}Read in binary outcome data; y outcome, x exposure, w covariate, z* instrumental variables (genotypes).{p_end}
{phang2}{cmd:.} {stata "use https://raw.github.com/remlapmot/ivonesamplemr/main/data/ivbinoutdata, clear"}{p_end}
{pstd}Fit the model with a single instrumental variable.{p_end}
{phang2}{cmd:.} {stata "ivmsmm y (x = z1)"}{p_end}
{pstd}Fit the model with multiple instruments.{p_end}
{phang2}{cmd:.} {stata "ivmsmm y (x = z1 z2 z3)"}{p_end}
{phang2}{cmd:.} {stata "estat overid"}{p_end}
{pstd}Adjusting for w.{p_end}
{phang2}{cmd:.} {stata "ivmsmm y w (x = z1 z2 z3)"}{p_end}
{pstd}Fit the model with multiple exposures, and instruments, and adjusting for w.{p_end}
{phang2}{cmd:.} {stata "ivmsmm y w (x1 x2 = z1 z2 z3)"}{p_end}
{phang2}{cmd:.} {stata "estat overid"}{p_end}
{pstd}Comparison with {cmd:ivpois} (specify {cmd:onestep} option to {cmd:ivmsmm}/{cmd:ivpoisson} for equivalence).{p_end}
{phang2}{cmd:.} {stata "ivpois y, endog(x) exog(z1) eform(RR)"}{p_end}
{phang2}{cmd:.} {stata "ivpois y, endog(x) exog(z1 z2 z3) eform(RR)"}{p_end}
{phang2}{cmd:.} {stata "ivpois y w, endog(x) exog(z1 z2 z3) eform(RR)"}{p_end}
{phang2}{cmd:.} {stata "ivpois y w, endog(x1 x2) exog(z1 z2 z3) eform(RR)"}{p_end}
{marker results}{...}
{title:Stored results}
{pstd}
Please see {help ivpoisson##results}{p_end}
{marker references}{...}
{title:References}
{marker cameron}{...}
{phang}
Cameron AC, Trivedi PK. Regression analysis of count data. 2nd ed. 2013. New York, Cambridge University Press.
{p_end}
{marker clarke}{...}
{phang}
Clarke PS, Palmer TM, Windmeijer F.
Estimating structural mean models with multiple instrumental variables using the Generalised Method of Moments.
Statistical Science, 2015, 30, 1, 96-117.
{browse "https://doi.org/10.1214/14-STS503":DOI}
{p_end}
{marker dukes}{...}
{phang}
Dukes O, Vansteelandt S.
A note on G-estimation of causal risk ratios.
American Journal of Epidemiology, 2018, 187, 5, 1079-1084.
{browse "https://doi.org/10.1093/aje/kwx347":DOI}
{p_end}
{marker hernan}{...}
{phang}
Hernán and Robins. Instruments for causal inference: An Epidemiologist's dream?
Epidemiology, 2006, 17, 360-372.
{browse "https://doi.org/10.1097/01.ede.0000222409.00878.37":DOI}
{p_end}
{marker mullahy}{...}
{phang}
Mullahy J. Instrumental-variable estimation of count data models:
applications to models of cigarette smoking and behavior.
The Review of Economics and Statistics. 1997, 79, 4, 586-593.
{browse "https://doi.org/10.1162/003465397557169":DOI}
{p_end}
{marker nichols}{...}
{phang}
Nichols A. ivpois: Stata module for IV/GMM Poisson regression. 2007.
{browse "http://ideas.repec.org/c/boc/bocode/s456890.html":URL}
{p_end}
{marker palmer-2011}{...}
{phang}
Palmer TM, Sterne JAC, Harbord RM, Lawlor DA, Sheehan NA, Meng S, Granell R, Davey Smith G, Didelez V.
Instrumental variable estimation of causal risk ratios and causal odds
ratios in Mendelian randomization analyses.
American Journal of Epidemiology, 2011, 173, 12, 1392-1403.
{browse "https://doi.org/10.1093/aje/kwr026":DOI}
{p_end}
{marker robins}{...}
{phang}
Robins JM.
The analysis of randomised and nonrandomised AIDS treatment trials using a new approach to
causal inference in longitudinal studies.
In Health Service Research Methodology: A Focus on AIDS
(L. Sechrest, H. Freeman and A. Mulley, eds.).
1989. 113–159. US Public Health Service, National Center for Health Services Research, Washington, DC.
{p_end}
{marker manivpoisson}{...}
{phang}
StataCorp. Stata Base Reference Manual. Release 13.
ivpoisson - Poisson model with continuous endogenous covariates. 2013.
{browse "https://www.stata.com/manuals13/rivpoisson.pdf":URL}
{p_end}
{marker windmeijer-1}{...}
{phang}
Windmeijer FAG, Santos Silva JMC. Endogeneity in Count Data Models:
An Application to Demand for Health Care.
Journal of Applied Econometrics. 1997, 12, 3, 281-294.
{browse "https://t.ly/3Et7":DOI}
{p_end}
{marker windmeijer-2}{...}
{phang}
Windmeijer, F.
ExpEnd, A Gauss programme for non-linear GMM estimation of EXPonential models with ENDogenous regressors
for cross section and panel data.
CEMMAP working paper CWP14/02. 2002.
{browse "https://www.cemmap.ac.uk/wp-content/uploads/2020/08/CWP1402.pdf":URL}
{p_end}
{marker author}{...}
{title:Author}
INCLUDE help ivonesamplemr-author