I want to estimate the impact of a state policy, adopted by different states at different times, on population standardized rates of poisonings. I have data from the 50 US states for 26 quarters. I have created a variable *post* that is an interaction of if the state is treated (ever adopted said policy) and its the quarters following treatement (post=treatMA*time_after_treat). My data looks as follows:
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input float(narc_nocod2 post) byte treatMA float(qavg_pct_lf_unemp pct_lhs pct_hs perc_black perc_nonwhite pctmale pctover65 state_share_rural_2010 md_100000 pa_100000 rn_100000 poly_all2) 2.769937 0 1 7.566667 7.7 27.7 4.545096 28.878407 .52014977 .08111796 .3398058 272.16888 70.290695 915.4395 2.769937 1.2464718 0 1 7.566667 7.7 27.7 4.545096 28.878407 .52014977 .08111796 .3398058 272.16888 70.290695 915.4395 .9694781 .9694781 0 1 7.733333 7.7 27.7 4.545096 28.878407 .52014977 .08111796 .3398058 272.16888 70.290695 915.4395 .9694781 3.7394154 0 1 7.5 7.7 27.7 4.545096 28.878407 .52014977 .08111796 .3398058 272.16888 70.290695 915.4395 3.323925 2.769937 0 1 7.733333 7.7 27.7 4.545096 28.878407 .52014977 .08111796 .3398058 272.16888 70.290695 915.4395 2.4929435 2.4929435 0 1 7.466667 7.7 27.7 4.545096 28.878407 .52014977 .08111796 .3398058 272.16888 70.290695 915.4395 2.4929435 1.1079749 0 1 7.5 7.7 27.7 4.545096 28.878407 .52014977 .08111796 .3398058 272.16888 70.290695 915.4395 1.1079749 1.938956 0 1 7.466667 7.7 27.7 4.545096 28.878407 .52014977 .08111796 .3398058 272.16888 70.290695 915.4395 1.938956 3.148964 0 1 7.166667 7.7 27.7 4.6983337 29.19467 .5209735 .0854725 .3398058 269.0507 69.48538 904.9514 3.012052 .8214688 0 1 7.166667 7.7 27.7 4.6983337 29.19467 .5209735 .0854725 .3398058 269.0507 69.48538 904.9514 .6845573 2.053672 0 1 7.333333 7.7 27.7 4.6983337 29.19467 .5209735 .0854725 .3398058 269.0507 69.48538 904.9514 1.9167606 .54764587 0 1 7.033333 7.7 27.7 4.6983337 29.19467 .5209735 .0854725 .3398058 269.0507 69.48538 904.9514 .54764587 2.4644065 0 1 7 7.7 27.7 4.6983337 29.19467 .5209735 .0854725 .3398058 269.0507 69.48538 904.9514 2.1905835 .6845573 0 1 7 7.7 27.7 4.6983337 29.19467 .5209735 .0854725 .3398058 269.0507 69.48538 904.9514 .6845573 1.779849 0 1 7.033333 7.7 27.7 4.6983337 29.19467 .5209735 .0854725 .3398058 269.0507 69.48538 904.9514 1.6429377 1.506026 0 1 7.333333 7.7 27.7 4.6983337 29.19467 .5209735 .0854725 .3398058 269.0507 69.48538 904.9514 1.506026 2.442185 0 1 7 7.7 27.7 4.786403 29.4967 .5228226 .08950587 .3398058 266.93665 68.93941 897.8408 2.1708307 1.3567692 0 1 7 7.7 27.7 4.786403 29.4967 .5228226 .08950587 .3398058 266.93665 68.93941 897.8408 1.3567692 2.1708307 0 1 7 7.7 27.7 4.786403 29.4967 .5228226 .08950587 .3398058 266.93665 68.93941 897.8408 2.1708307 .8140616 0 1 7 7.7 27.7 4.786403 29.4967 .5228226 .08950587 .3398058 266.93665 68.93941 897.8408 .8140616 2.442185 0 1 7 7.7 27.7 4.786403 29.4967 .5228226 .08950587 .3398058 266.93665 68.93941 897.8408 2.442185 1.3567692 0 1 7 7.7 27.7 4.786403 29.4967 .5228226 .08950587 .3398058 266.93665 68.93941 897.8408 1.3567692 1.2210923 0 1 7 7.7 27.7 4.786403 29.4967 .5228226 .08950587 .3398058 266.93665 68.93941 897.8408 1.2210923 .27135384 0 1 7 7.7 27.7 4.786403 29.4967 .5228226 .08950587 .3398058 266.93665 68.93941 897.8408 .27135384 .6790646 0 1 7 7.7 27.7 4.795406 29.827 .5233248 .09415574 .3398058 266.9997 68.95569 898.0528 .6790646 2.1730065 0 1 7 7.7 27.7 4.795406 29.827 .5233248 .09415574 .3398058 266.9997 68.95569 898.0528 1.9013808 2.1730065 0 1 6.6 7.7 27.7 4.795406 29.827 .5233248 .09415574 .3398058 266.9997 68.95569 898.0528 1.9013808 2.4446325 0 1 6.866667 7.7 27.7 4.795406 29.827 .5233248 .09415574 .3398058 266.9997 68.95569 898.0528 2.3088195 1.2223163 0 1 6.6 7.7 27.7 4.795406 29.827 .5233248 .09415574 .3398058 266.9997 68.95569 898.0528 1.0865033 .9506904 0 1 7 7.7 27.7 4.795406 29.827 .5233248 .09415574 .3398058 266.9997 68.95569 898.0528 .9506904 1.0865033 0 1 7 7.7 27.7 4.795406 29.827 .5233248 .09415574 .3398058 266.9997 68.95569 898.0528 1.0865033 .8148775 0 1 6.866667 7.7 27.7 4.795406 29.827 .5233248 .09415574 .3398058 266.9997 68.95569 898.0528 .6790646 2.7116916 0 1 6.633333 7.7 27.7 4.818702 30.10442 .5234001 .09878014 .3398058 266.6363 68.86184 896.8306 2.7116916 .949092 0 1 6.5 7.7 27.7 4.818702 30.10442 .5234001 .09878014 .3398058 266.6363 68.86184 896.8306 .8135075 .8135075 0 1 6.5 7.7 27.7 4.818702 30.10442 .5234001 .09878014 .3398058 266.6363 68.86184 896.8306 .8135075 3.1184454 0 1 6.5 7.7 27.7 4.818702 30.10442 .5234001 .09878014 .3398058 266.6363 68.86184 896.8306 3.1184454 .8135075 0 1 6.5 7.7 27.7 4.818702 30.10442 .5234001 .09878014 .3398058 266.6363 68.86184 896.8306 .8135075 2.0337687 0 1 6.5 7.7 27.7 4.818702 30.10442 .5234001 .09878014 .3398058 266.6363 68.86184 896.8306 1.898184 1.627015 0 1 6.5 7.7 27.7 4.818702 30.10442 .5234001 .09878014 .3398058 266.6363 68.86184 896.8306 1.4914304 .40675375 0 1 6.633333 7.7 27.7 4.818702 30.10442 .5234001 .09878014 .3398058 266.6363 68.86184 896.8306 .40675375 1.0788883 0 1 6.866667 7.7 27.7 4.911483 30.41499 .5231637 .10406608 .3398058 265.1322 68.4734 891.7716 1.0788883 1.4834714 0 1 7 7.7 27.7 4.911483 30.41499 .5231637 .10406608 .3398058 265.1322 68.4734 891.7716 .9440272 1.6183325 0 1 6.766667 7.7 27.7 4.911483 30.41499 .5231637 .10406608 .3398058 265.1322 68.4734 891.7716 1.4834714 2.56236 0 1 6.766667 7.7 27.7 4.911483 30.41499 .5231637 .10406608 .3398058 265.1322 68.4734 891.7716 2.427499 2.966943 0 1 7 7.7 27.7 4.911483 30.41499 .5231637 .10406608 .3398058 265.1322 68.4734 891.7716 2.697221 1.2137494 0 1 7 7.7 27.7 4.911483 30.41499 .5231637 .10406608 .3398058 265.1322 68.4734 891.7716 1.2137494 1.3486104 0 1 6.866667 7.7 27.7 4.911483 30.41499 .5231637 .10406608 .3398058 265.1322 68.4734 891.7716 1.2137494 .6743052 0 1 7 7.7 27.7 4.911483 30.41499 .5231637 .10406608 .3398058 265.1322 68.4734 891.7716 .6743052 1.4869165 0 1 7.133333 7.7 27.7 . . . . .3398058 265.8877 68.66851 894.3127 1.4869165 1.3517423 0 1 7.033333 7.7 27.7 . . . . .3398058 265.8877 68.66851 894.3127 1.216568 2.1627877 0 1 7.033333 7.7 27.7 . . . . .3398058 265.8877 68.66851 894.3127 2.0276134 2.7034845 0 1 7.133333 7.7 27.7 . . . . .3398058 265.8877 68.66851 894.3127 2.7034845 1.2919805 0 0 9.666667 15.2 31 26.847376 28.9922 .4852006 .14009614 .4096304 209.7536 29.958845 1025.8926 1.271142 2.2713852 0 0 8.633333 15.2 31 26.847376 28.9922 .4852006 .14009614 .4096304 209.7536 29.958845 1025.8926 2.0213244 1.312819 0 0 10 15.2 31 26.847376 28.9922 .4852006 .14009614 .4096304 209.7536 29.958845 1025.8926 1.271142 1.3336573 0 0 10.166667 15.2 31 26.847376 28.9922 .4852006 .14009614 .4096304 209.7536 29.958845 1025.8926 1.208627 2.646476 0 0 10.166667 15.2 31 26.847376 28.9922 .4852006 .14009614 .4096304 209.7536 29.958845 1025.8926 2.313062 2.5006075 0 0 10 15.2 31 26.847376 28.9922 .4852006 .14009614 .4096304 209.7536 29.958845 1025.8926 2.1255164 1.0835966 0 0 8.633333 15.2 31 26.847376 28.9922 .4852006 .14009614 .4096304 209.7536 29.958845 1025.8926 .9585662 2.2922235 0 0 9.666667 15.2 31 26.847376 28.9922 .4852006 .14009614 .4096304 209.7536 29.958845 1025.8926 2.1671932 1.34979 0 0 8.2 15.2 31 26.951054 29.14335 .4851257 .14522338 .4096304 209.0549 29.85905 1022.4753 1.308258 1.55745 0 0 8.066667 15.2 31 26.951054 29.14335 .4851257 .14522338 .4096304 209.0549 29.85905 1022.4753 1.495152 2.18043 0 0 8 15.2 31 26.951054 29.14335 .4851257 .14522338 .4096304 209.0549 29.85905 1022.4753 1.910472 2.554218 0 0 7.666667 15.2 31 26.951054 29.14335 .4851257 .14522338 .4096304 209.0549 29.85905 1022.4753 2.138898 1.515918 0 0 7.666667 15.2 31 26.951054 29.14335 .4851257 .14522338 .4096304 209.0549 29.85905 1022.4753 1.474386 1.370556 0 0 8 15.2 31 26.951054 29.14335 .4851257 .14522338 .4096304 209.0549 29.85905 1022.4753 1.225194 2.761878 0 0 8.2 15.2 31 26.951054 29.14335 .4851257 .14522338 .4096304 209.0549 29.85905 1022.4753 2.305026 2.637282 0 0 8.066667 15.2 31 26.951054 29.14335 .4851257 .14522338 .4096304 209.0549 29.85905 1022.4753 2.3465579 1.3249255 0 0 7.1 15.2 31 27.068136 29.300863 .4850109 .14920263 .4096304 208.4697 29.77547 1019.6131 1.2628196 2.21511 0 0 7.133333 15.2 31 27.068136 29.300863 .4850109 .14920263 .4096304 208.4697 29.77547 1019.6131 1.9459845 1.3456275 0 0 7.4 15.2 31 27.068136 29.300863 .4850109 .14920263 .4096304 208.4697 29.77547 1019.6131 1.2214158 1.2835217 0 0 7.133333 15.2 31 27.068136 29.300863 .4850109 .14920263 .4096304 208.4697 29.77547 1019.6131 1.2214158 2.649851 0 0 7.4 15.2 31 27.068136 29.300863 .4850109 .14920263 .4096304 208.4697 29.77547 1019.6131 2.173706 1.9252825 0 0 7.233333 15.2 31 27.068136 29.300863 .4850109 .14920263 .4096304 208.4697 29.77547 1019.6131 1.573349 2.1530042 0 0 7.1 15.2 31 27.068136 29.300863 .4850109 .14920263 .4096304 208.4697 29.77547 1019.6131 1.9459845 1.594051 0 0 7.233333 15.2 31 27.068136 29.300863 .4850109 .14920263 .4096304 208.4697 29.77547 1019.6131 1.573349 1.7965997 0 0 7.233333 15.2 31 27.15205 29.434875 .4848089 .15354267 .4096304 207.8785 29.691027 1016.7216 1.4042388 1.6520457 0 0 6.233333 15.2 31 27.15205 29.434875 .4848089 .15354267 .4096304 207.8785 29.691027 1016.7216 1.3629377 2.127009 0 0 6.6 15.2 31 27.15205 29.434875 .4848089 .15354267 .4096304 207.8785 29.691027 1016.7216 2.0031054 1.548793 0 0 6.6 15.2 31 27.15205 29.434875 .4848089 .15354267 .4096304 207.8785 29.691027 1016.7216 1.5281423 1.7139975 0 0 7 15.2 31 27.15205 29.434875 .4848089 .15354267 .4096304 207.8785 29.691027 1016.7216 1.5074917 1.5074917 0 0 7.233333 15.2 31 27.15205 29.434875 .4848089 .15354267 .4096304 207.8785 29.691027 1016.7216 1.4248894 1.5694435 0 0 7 15.2 31 27.15205 29.434875 .4848089 .15354267 .4096304 207.8785 29.691027 1016.7216 1.5281423 1.3422872 0 0 6.233333 15.2 31 27.15205 29.434875 .4848089 .15354267 .4096304 207.8785 29.691027 1016.7216 1.300986 1.6072003 0 0 6 15.2 31 27.26294 29.60861 .484659 .1574272 .4096304 207.4219 29.625814 1014.4884 1.421754 1.3187284 0 0 6.1 15.2 31 27.26294 29.60861 .484659 .1574272 .4096304 207.4219 29.625814 1014.4884 1.1332822 1.0714668 0 0 6.1 15.2 31 27.26294 29.60861 .484659 .1574272 .4096304 207.4219 29.625814 1014.4884 1.0714668 1.6072003 0 0 6.1 15.2 31 27.26294 29.60861 .484659 .1574272 .4096304 207.4219 29.625814 1014.4884 1.4835695 .9684412 0 0 6.166667 15.2 31 27.26294 29.60861 .484659 .1574272 .4096304 207.4219 29.625814 1014.4884 .9066258 1.730831 0 0 6.166667 15.2 31 27.26294 29.60861 .484659 .1574272 .4096304 207.4219 29.625814 1014.4884 1.586595 1.236308 0 0 6.1 15.2 31 27.26294 29.60861 .484659 .1574272 .4096304 207.4219 29.625814 1014.4884 1.2157028 1.256913 0 0 6 15.2 31 27.26294 29.60861 .484659 .1574272 .4096304 207.4219 29.625814 1014.4884 1.2157028 1.1100273 0 0 5.833333 15.2 31 27.34045 29.740936 .4843596 .1613207 .4096304 207.01993 29.5684 1012.5223 1.0689152 1.6033728 0 0 5.833333 15.2 31 27.34045 29.740936 .4843596 .1613207 .4096304 207.01993 29.5684 1012.5223 1.4594804 1.0278031 0 0 5.966667 15.2 31 27.34045 29.740936 .4843596 .1613207 .4096304 207.01993 29.5684 1012.5223 .986691 1.8089335 0 0 5.966667 15.2 31 27.34045 29.740936 .4843596 .1613207 .4096304 207.01993 29.5684 1012.5223 1.623929 1.0072471 0 0 5.8 15.2 31 27.34045 29.740936 .4843596 .1613207 .4096304 207.01993 29.5684 1012.5223 .9661349 1.4389243 0 0 5.833333 15.2 31 27.34045 29.740936 .4843596 .1613207 .4096304 207.01993 29.5684 1012.5223 1.2744758 1.7472652 0 0 5.8 15.2 31 27.34045 29.740936 .4843596 .1613207 .4096304 207.01993 29.5684 1012.5223 1.5417047 1.377256 0 0 5.833333 15.2 31 27.34045 29.740936 .4843596 .1613207 .4096304 207.01993 29.5684 1012.5223 1.336144 end
Code:
reghdfe narc_nocod2 post treatMA qavg_pct_lf_unemp pct_lhs pct_hs perc_black perc_non > white pctmale pctover65 /// > state_share_rural_2010 md_100000 pa_100000 rn_100000 [weight=popestimate] if outcome==2 > , absorb(i.qtr i.stateFIPS i.stateFIPS#(c.qtr c.qtrsq)) vce(cluster stateFIPS) (analytic weights assumed) weight popestimate can only contain strictly positive reals, but 1 missing values were fo > und (will be dropped) (converged in 9 iterations) note: treatMA omitted because of collinearity note: pct_lhs omitted because of collinearity note: pct_hs omitted because of collinearity note: state_share_rural_2010 omitted because of collinearity HDFE Linear regression Number of obs = 1,128 Absorbing 3 HDFE groups F( 9, 46) = 1.79 Statistics robust to heteroskedasticity Prob > F = 0.0969 R-squared = 1.0000 Adj R-squared = 1.0000 Within R-sq. = 0.0143 Number of clusters (stateFIPS) = 47 Root MSE = 0.1546 (Std. Err. adjusted for 47 clusters in stateFIPS) ---------------------------------------------------------------------------------------- | Robust narc_nocod2 | Coef. Std. Err. t P>|t| [95% Conf. Interval] -----------------------+---------------------------------------------------------------- post | .0987154 .0343737 2.87 0.006 .0295247 .167906 treatMA | 0 (omitted) qavg_pct_lf_unemp | -.0056164 .0205179 -0.27 0.786 -.0469167 .0356839 pct_lhs | 0 (omitted) pct_hs | 0 (omitted) perc_black | -.1040779 .3172873 -0.33 0.744 -.7427441 .5345884 perc_nonwhite | .0279966 .2423516 0.12 0.909 -.4598319 .5158251 pctmale | 101.4251 95.03542 1.07 0.291 -89.8713 292.7215 pctover65 | 49.40179 21.94308 2.25 0.029 5.232655 93.57092 state_share_rural_2010 | 0 (omitted) md_100000 | -.0401727 .0841578 -0.48 0.635 -.2095736 .1292282 pa_100000 | .0077521 .2196394 0.04 0.972 -.434359 .4498633 rn_100000 | .0109752 .0256446 0.43 0.671 -.0406447 .0625951 ---------------------------------------------------------------------------------------- Absorbed degrees of freedom: -------------------------------------------------------------------------+ Absorbed FE | Num. Coefs. = Categories - Redundant | -----------------------+-------------------------------------------------| qtr | 24 24 0 | stateFIPS | 0 47 47 * | stateFIPS#c.qtr | 47 47 0 ? | stateFIPS#c.qtrsq | 47 47 0 ? | -------------------------------------------------------------------------+ ? = number of redundant parameters may be higher * = fixed effect nested within cluster; treated as redundant for DoF computation
Code:
reghdfe narc_nocod2 post poly_all2 treatMA qavg_pct_lf_unemp pct_lhs pct_hs perc_black > perc_nonwhite pctmale pctover65 /// > state_share_rural_2010 md_100000 pa_100000 rn_100000 [weight=popestimate] if outcome==2 > , absorb(i.qtr i.stateFIPS i.stateFIPS#(c.qtr c.qtrsq)) vce(cluster stateFIPS) (analytic weights assumed) weight popestimate can only contain strictly positive reals, but 1 missing values were fo > und (will be dropped) (converged in 9 iterations) note: treatMA omitted because of collinearity note: pct_lhs omitted because of collinearity note: pct_hs omitted because of collinearity note: state_share_rural_2010 omitted because of collinearity HDFE Linear regression Number of obs = 1,128 Absorbing 3 HDFE groups F( 10, 46) = 1988.38 Statistics robust to heteroskedasticity Prob > F = 0.0000 R-squared = 1.0000 Adj R-squared = 1.0000 Within R-sq. = 0.9788 Number of clusters (stateFIPS) = 47 Root MSE = 0.0227 (Std. Err. adjusted for 47 clusters in stateFIPS) ---------------------------------------------------------------------------------------- | Robust narc_nocod2 | Coef. Std. Err. t P>|t| [95% Conf. Interval] -----------------------+---------------------------------------------------------------- post | .0054146 .0054542 0.99 0.326 -.0055642 .0163933 poly_all2 | 1.013471 .0073252 138.35 0.000 .9987264 1.028216 treatMA | 0 (omitted) qavg_pct_lf_unemp | .0035934 .0035235 1.02 0.313 -.003499 .0106859 pct_lhs | 0 (omitted) pct_hs | 0 (omitted) perc_black | -.0160729 .0531401 -0.30 0.764 -.1230383 .0908926 perc_nonwhite | .0011686 .0416198 0.03 0.978 -.0826076 .0849448 pctmale | 14.45668 11.13663 1.30 0.201 -7.960195 36.87355 pctover65 | 1.889488 3.229166 0.59 0.561 -4.610485 8.389461 state_share_rural_2010 | 0 (omitted) md_100000 | .0083453 .0063331 1.32 0.194 -.0044026 .0210932 pa_100000 | .0193383 .0219901 0.88 0.384 -.0249255 .0636022 rn_100000 | -.0029487 .0016219 -1.82 0.076 -.0062134 .0003161 ---------------------------------------------------------------------------------------- Absorbed degrees of freedom: -------------------------------------------------------------------------+ Absorbed FE | Num. Coefs. = Categories - Redundant | -----------------------+-------------------------------------------------| qtr | 24 24 0 | stateFIPS | 0 47 47 * | stateFIPS#c.qtr | 47 47 0 ? | stateFIPS#c.qtrsq | 47 47 0 ? | -------------------------------------------------------------------------+ ? = number of redundant parameters may be higher * = fixed effect nested within cluster; treated as redundant for DoF computation
I want to check if the increase in poisonings is therefore mediated by an increase in poly-drug poisonings. My understanding is that the structural sem command can help me pin down any mediation effect? However, it is not clear to me what should the specification be? I tried the following:
Code:
sem (narc_nocod2 <- post poly_all2 treatMA qavg_pct_lf_unemp pct_lhs pct_hs perc_bl > ack perc_nonwhite pctmale pctover65 /// // perfect > state_share_rural_2010 md_100000 pa_100000 rn_100000 _IstateFIPs_* _IstaXqtrs_* qtrdum > * statedum*) (lnpoly_all2 <- post) (396 observations with missing values excluded) Endogenous variables Observed: narc_nocod2 lnpoly_all2 Exogenous variables Observed: post poly_all2 treatMA qavg_pct_lf_unemp pct_lhs pct_hs perc_black perc_nonwhite pctmale pctover65 state_share_rural_2010 md_100000 pa_100000 rn_100000 _IstateFIPs_2 _IstateFIPs_4 _IstateFIPs_5 _IstateFIPs_6 _IstateFIPs_8 _IstateFIPs_9 _IstateFIPs_11 _IstateFIPs_12 _IstateFIPs_13 _IstateFIPs_15 _IstateFIPs_16 _IstateFIPs_17 _IstateFIPs_18 _IstateFIPs_19 _IstateFIPs_20 _IstateFIPs_21 _IstateFIPs_22 _IstateFIPs_23 _IstateFIPs_24 _IstateFIPs_25 _IstateFIPs_26 _IstateFIPs_27 _IstateFIPs_28 _IstateFIPs_29 _IstateFIPs_30 _IstateFIPs_31 _IstateFIPs_32 _IstateFIPs_33 _IstateFIPs_34 _IstateFIPs_35 _IstateFIPs_36 _IstateFIPs_37 _IstateFIPs_38 _IstateFIPs_39 _IstateFIPs_40 _IstateFIPs_41 _IstateFIPs_42 _IstateFIPs_44 _IstateFIPs_45 _IstateFIPs_46 _IstateFIPs_47 _IstateFIPs_48 _IstateFIPs_49 _IstateFIPs_50 _IstateFIPs_51 _IstateFIPs_53 _IstateFIPs_54 _IstateFIPs_55 _IstateFIPs_56 _IstaXqtrs_2 _IstaXqtrs_4 _IstaXqtrs_5 _IstaXqtrs_6 _IstaXqtrs_8 _IstaXqtrs_9 _IstaXqtrs_11 _IstaXqtrs_12 _IstaXqtrs_13 _IstaXqtrs_15 _IstaXqtrs_16 _IstaXqtrs_17 _IstaXqtrs_18 _IstaXqtrs_19 _IstaXqtrs_20 _IstaXqtrs_21 _IstaXqtrs_22 _IstaXqtrs_23 _IstaXqtrs_24 _IstaXqtrs_25 _IstaXqtrs_26 _IstaXqtrs_27 _IstaXqtrs_28 _IstaXqtrs_29 _IstaXqtrs_30 _IstaXqtrs_31 _IstaXqtrs_32 _IstaXqtrs_33 _IstaXqtrs_34 _IstaXqtrs_35 _IstaXqtrs_36 _IstaXqtrs_37 _IstaXqtrs_38 _IstaXqtrs_39 _IstaXqtrs_40 _IstaXqtrs_41 _IstaXqtrs_42 _IstaXqtrs_44 _IstaXqtrs_45 _IstaXqtrs_46 _IstaXqtrs_47 _IstaXqtrs_48 _IstaXqtrs_49 _IstaXqtrs_50 _IstaXqtrs_51 _IstaXqtrs_53 _IstaXqtrs_54 _IstaXqtrs_55 _IstaXqtrs_56 qtrdum1 qtrdum2 qtrdum3 qtrdum4 qtrdum5 qtrdum6 qtrdum7 qtrdum8 qtrdum9 qtrdum10 qtrdum11 qtrdum12 qtrdum13 qtrdum14 qtrdum15 qtrdum16 qtrdum17 qtrdum18 qtrdum19 qtrdum20 qtrdum21 qtrdum22 qtrdum23 qtrdum24 qtrdum25 qtrdum26 statedum1 statedum2 statedum3 statedum4 statedum5 statedum6 statedum7 statedum8 statedum9 statedum10 statedum11 statedum12 statedum13 statedum14 statedum15 statedum16 statedum17 statedum18 statedum19 statedum20 statedum21 statedum22 statedum23 statedum24 statedum25 statedum26 statedum27 statedum28 statedum29 statedum30 statedum31 statedum32 statedum33 statedum34 statedum35 statedum36 statedum37 statedum38 statedum39 statedum40 statedum41 statedum42 statedum43 statedum44 statedum45 statedum46 statedum47 statedum48 statedum49 statedum50 statedum51 Fitting target model: Iteration 0: log likelihood = -487821.11 (not concave) Iteration 1: log likelihood = -487821.11 (not concave) Iteration 2: log likelihood = -487821.11 (not concave) Iteration 3: log likelihood = -487821.11 (not concave) Iteration 4: log likelihood = -487821.11 (not concave) Iteration 5: log likelihood = -487821.11 (not concave) Iteration 6: log likelihood = -487821.11 (not concave) Iteration 7: log likelihood = -487821.11 (not concave) Iteration 8: log likelihood = -487821.11 (not concave) Iteration 9: log likelihood = -487821.11 (not concave) Iteration 10: log likelihood = -487821.11 (not concave) Iteration 11: log likelihood = -487821.11 (not concave) Iteration 12: log likelihood = -487821.11 (not concave) Iteration 13: log likelihood = -487821.11 (not concave) Iteration 14: log likelihood = -487821.11 (not concave) Iteration 15: log likelihood = -487821.11 (not concave)
I tried a much simpler model:
Code:
sem (poly_all2 <- post)(narc_nocod2 <- poly_all2 post) (1 observations with missing values excluded) Endogenous variables Observed: poly_all2 narc_nocod2 Exogenous variables Observed: post Fitting target model: Iteration 0: log likelihood = -1772.9944 Iteration 1: log likelihood = -1772.9944 Structural equation model Number of obs = 2,651 Estimation method = ml Log likelihood = -1772.9944 ----------------------------------------------------------------------------------- | OIM | Coef. Std. Err. z P>|z| [95% Conf. Interval] ------------------+---------------------------------------------------------------- Structural | poly_all2 <- | post | -.2279079 .0423372 -5.38 0.000 -.3108872 -.1449286 _cons | 1.550983 .0186604 83.12 0.000 1.514409 1.587556 ----------------+---------------------------------------------------------------- narc_nocod2 <- | poly_all2 | 1.07609 .0018252 589.58 0.000 1.072513 1.079667 post | -.0019335 .0040003 -0.48 0.629 -.0097739 .0059069 _cons | -.0177858 .00333 -5.34 0.000 -.0243124 -.0112592 ------------------+---------------------------------------------------------------- var(e.poly_all2)| .7437761 .0204292 .7047942 .784914 var(e.narc_nocod2)| .0065684 .0001804 .0062241 .0069317 ----------------------------------------------------------------------------------- LR test of model vs. saturated: chi2(0) = 0.00, Prob > chi2 = .
Is this a correct specification? How should these results be interpreted in terms of mediation by poly_all2?
Thank you in advance for your help.
Sincerely,
Sumedha.
0 Response to Mediation in generalized differnce-in-difference.
Post a Comment