------------------------------------------------------------------------------------------------------------- log: d:\spost.stata8\do\st8ch6.log log type: text opened on: 26 May 2003, 12:50:02 . . // * . // * RM4STATA Ch 6: Models for Nominal Outcomes - 5/26/2003 . // * . . // * Section 6.2: the multinomial logit model . . * construct new outcome variables with 2 or 3 categories . use nomocc2, clear (1982 General Social Survey) . tab occ Occupation | Freq. Percent Cum. ------------+----------------------------------- Menial | 31 9.20 9.20 BlueCol | 69 20.47 29.67 Craft | 84 24.93 54.60 WhiteCol | 41 12.17 66.77 Prof | 112 33.23 100.00 ------------+----------------------------------- Total | 337 100.00 . gen occ3 = occ . recode occ3 1/3=1 4=2 5=3 (occ3: 306 changes made) . label def locc3 1 Manual 2 WhiteCol 3 Prof . label val occ3 locc3 . tab occ occ3,miss | occ3 Occupation | Manual WhiteCol Prof | Total -----------+---------------------------------+---------- Menial | 31 0 0 | 31 BlueCol | 69 0 0 | 69 Craft | 84 0 0 | 84 WhiteCol | 0 41 0 | 41 Prof | 0 0 112 | 112 -----------+---------------------------------+---------- Total | 184 41 112 | 337 . gen wc_man= occ3==2 if occ3~=3 (112 missing values generated) . gen prof_man = occ3==3 if occ3~=2 (41 missing values generated) . gen prof_wc = occ3==3 if occ3~=1 (184 missing values generated) . label def lwm 1 WhiteCol 0 Manual . label def lpm 1 Prof 0 Manual . label def lpw 1 Prof 0 WhiteCol . label val wc_man lwm . label val prof_man lpm . label val prof_wc lpw . tab occ3 wc_man, miss | wc_man occ3 | Manual WhiteCol . | Total -----------+---------------------------------+---------- Manual | 184 0 0 | 184 WhiteCol | 0 41 0 | 41 Prof | 0 0 112 | 112 -----------+---------------------------------+---------- Total | 184 41 112 | 337 . tab occ3 prof_man, miss | prof_man occ3 | Manual Prof . | Total -----------+---------------------------------+---------- Manual | 184 0 0 | 184 WhiteCol | 0 0 41 | 41 Prof | 0 112 0 | 112 -----------+---------------------------------+---------- Total | 184 112 41 | 337 . tab occ3 prof_wc, miss | prof_wc occ3 | WhiteCol Prof . | Total -----------+---------------------------------+---------- Manual | 0 0 184 | 184 WhiteCol | 41 0 0 | 41 Prof | 0 112 0 | 112 -----------+---------------------------------+---------- Total | 41 112 184 | 337 . tab prof_man, miss prof_man | Freq. Percent Cum. ------------+----------------------------------- Manual | 184 54.60 54.60 Prof | 112 33.23 87.83 . | 41 12.17 100.00 ------------+----------------------------------- Total | 337 100.00 . . * binary logits . tab prof_man, miss prof_man | Freq. Percent Cum. ------------+----------------------------------- Manual | 184 54.60 54.60 Prof | 112 33.23 87.83 . | 41 12.17 100.00 ------------+----------------------------------- Total | 337 100.00 . logit prof_man ed, nolog Logit estimates Number of obs = 296 LR chi2(1) = 139.78 Prob > chi2 = 0.0000 Log likelihood = -126.43879 Pseudo R2 = 0.3560 ------------------------------------------------------------------------------ prof_man | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- ed | .7184599 .0858735 8.37 0.000 .550151 .8867688 _cons | -10.19854 1.177457 -8.66 0.000 -12.50632 -7.89077 ------------------------------------------------------------------------------ . . * estimate the corresponding multinomial logit . tab occ3, miss occ3 | Freq. Percent Cum. ------------+----------------------------------- Manual | 184 54.60 54.60 WhiteCol | 41 12.17 66.77 Prof | 112 33.23 100.00 ------------+----------------------------------- Total | 337 100.00 . mlogit occ3 ed, nolog Multinomial logistic regression Number of obs = 337 LR chi2(2) = 145.89 Prob > chi2 = 0.0000 Log likelihood = -248.14786 Pseudo R2 = 0.2272 ------------------------------------------------------------------------------ occ3 | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- WhiteCol | ed | .3000735 .0841358 3.57 0.000 .1351703 .4649767 _cons | -5.232602 1.096086 -4.77 0.000 -7.380892 -3.084312 -------------+---------------------------------------------------------------- Prof | ed | .7195673 .0805117 8.94 0.000 .5617671 .8773674 _cons | -10.21121 1.106913 -9.22 0.000 -12.38072 -8.041698 ------------------------------------------------------------------------------ (Outcome occ3==Manual is the comparison group) . . * effect of different category values for outcome . gen occ999 = occ3 . recode occ999 1=-3 2=0 3=999 (occ999: 337 changes made) . mlogit occ3 ed, nolog b(3) Multinomial logistic regression Number of obs = 337 LR chi2(2) = 145.89 Prob > chi2 = 0.0000 Log likelihood = -248.14786 Pseudo R2 = 0.2272 ------------------------------------------------------------------------------ occ3 | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Manual | ed | -.7195673 .0805117 -8.94 0.000 -.8773674 -.5617671 _cons | 10.21121 1.106913 9.22 0.000 8.041698 12.38072 -------------+---------------------------------------------------------------- WhiteCol | ed | -.4194938 .0890477 -4.71 0.000 -.594024 -.2449636 _cons | 4.978606 1.244262 4.00 0.000 2.539898 7.417315 ------------------------------------------------------------------------------ (Outcome occ3==Prof is the comparison group) . mlogit occ999 ed, nolog b(999) Multinomial logistic regression Number of obs = 337 LR chi2(2) = 145.89 Prob > chi2 = 0.0000 Log likelihood = -248.14786 Pseudo R2 = 0.2272 ------------------------------------------------------------------------------ occ999 | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- -3 | ed | -.7195673 .0805117 -8.94 0.000 -.8773674 -.5617671 _cons | 10.21121 1.106913 9.22 0.000 8.041698 12.38072 -------------+---------------------------------------------------------------- 0 | ed | -.4194938 .0890477 -4.71 0.000 -.594024 -.2449636 _cons | 4.978606 1.244262 4.00 0.000 2.539898 7.417315 ------------------------------------------------------------------------------ (Outcome occ999==999 is the comparison group) . . // * Section 6.2.1: example of occupational attainment . . desc white ed exper storage display value variable name type format label variable label ------------------------------------------------------------------------------- white byte %10.0g Race: 1=white 0=nonwhite ed byte %10.0g Years of education exper byte %10.0g Years of work experience . sum white ed exper Variable | Obs Mean Std. Dev. Min Max -------------+-------------------------------------------------------- white | 337 .9169139 .2764227 0 1 ed | 337 13.09496 2.946427 3 20 exper | 337 20.50148 13.95936 2 66 . tab occ Occupation | Freq. Percent Cum. ------------+----------------------------------- Menial | 31 9.20 9.20 BlueCol | 69 20.47 29.67 Craft | 84 24.93 54.60 WhiteCol | 41 12.17 66.77 Prof | 112 33.23 100.00 ------------+----------------------------------- Total | 337 100.00 . mlogit occ white ed exper, basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . . // * Section 6.2.2: using different base categories . . listcoef white, help mlogit (N=337): Factor Change in the Odds of occ Variable: white (sd= .28) Odds comparing| Group 1 vs Group 2| b z P>|z| e^b e^bStdX ------------------+--------------------------------------------- Menial -BlueCol | -1.23650 -1.707 0.088 0.2904 0.7105 Menial -Craft | -0.47234 -0.782 0.434 0.6235 0.8776 Menial -WhiteCol | -1.57139 -1.741 0.082 0.2078 0.6477 Menial -Prof | -1.77431 -2.350 0.019 0.1696 0.6123 BlueCol -Menial | 1.23650 1.707 0.088 3.4436 1.4075 BlueCol -Craft | 0.76416 1.208 0.227 2.1472 1.2352 BlueCol -WhiteCol | -0.33488 -0.359 0.720 0.7154 0.9116 BlueCol -Prof | -0.53780 -0.673 0.501 0.5840 0.8619 Craft -Menial | 0.47234 0.782 0.434 1.6037 1.1395 Craft -BlueCol | -0.76416 -1.208 0.227 0.4657 0.8096 Craft -WhiteCol | -1.09904 -1.343 0.179 0.3332 0.7380 Craft -Prof | -1.30196 -2.011 0.044 0.2720 0.6978 WhiteCol-Menial | 1.57139 1.741 0.082 4.8133 1.5440 WhiteCol-BlueCol | 0.33488 0.359 0.720 1.3978 1.0970 WhiteCol-Craft | 1.09904 1.343 0.179 3.0013 1.3550 WhiteCol-Prof | -0.20292 -0.233 0.815 0.8163 0.9455 Prof -Menial | 1.77431 2.350 0.019 5.8962 1.6331 Prof -BlueCol | 0.53780 0.673 0.501 1.7122 1.1603 Prof -Craft | 1.30196 2.011 0.044 3.6765 1.4332 Prof -WhiteCol | 0.20292 0.233 0.815 1.2250 1.0577 ---------------------------------------------------------------- b = raw coefficient z = z-score for test of b=0 P>|z| = p-value for z-test e^b = exp(b) = factor change in odds for unit increase in X e^bStdX = exp(b*SD of X) = change in odds for SD increase in X . listcoef, pvalue(.05) mlogit (N=337): Factor Change in the Odds of occ when P>|z| < 0.05 Variable: white (sd= .28) Odds comparing| Group 1 vs Group 2| b z P>|z| e^b e^bStdX ------------------+--------------------------------------------- Menial -Prof | -1.77431 -2.350 0.019 0.1696 0.6123 Craft -Prof | -1.30196 -2.011 0.044 0.2720 0.6978 Prof -Menial | 1.77431 2.350 0.019 5.8962 1.6331 Prof -Craft | 1.30196 2.011 0.044 3.6765 1.4332 ---------------------------------------------------------------- Variable: ed (sd= 2.9) Odds comparing| Group 1 vs Group 2| b z P>|z| e^b e^bStdX ------------------+--------------------------------------------- Menial -WhiteCol | -0.35316 -3.011 0.003 0.7025 0.3533 Menial -Prof | -0.77885 -6.795 0.000 0.4589 0.1008 BlueCol -Craft | -0.19324 -2.494 0.013 0.8243 0.5659 BlueCol -WhiteCol | -0.45258 -4.425 0.000 0.6360 0.2636 BlueCol -Prof | -0.87828 -8.735 0.000 0.4155 0.0752 Craft -BlueCol | 0.19324 2.494 0.013 1.2132 1.7671 Craft -WhiteCol | -0.25934 -2.773 0.006 0.7716 0.4657 Craft -Prof | -0.68504 -7.671 0.000 0.5041 0.1329 WhiteCol-Menial | 0.35316 3.011 0.003 1.4236 2.8308 WhiteCol-BlueCol | 0.45258 4.425 0.000 1.5724 3.7943 WhiteCol-Craft | 0.25934 2.773 0.006 1.2961 2.1471 WhiteCol-Prof | -0.42569 -4.616 0.000 0.6533 0.2853 Prof -Menial | 0.77885 6.795 0.000 2.1790 9.9228 Prof -BlueCol | 0.87828 8.735 0.000 2.4067 13.3002 Prof -Craft | 0.68504 7.671 0.000 1.9838 7.5264 Prof -WhiteCol | 0.42569 4.616 0.000 1.5307 3.5053 ---------------------------------------------------------------- Variable: exper (sd= 14) Odds comparing| Group 1 vs Group 2| b z P>|z| e^b e^bStdX ------------------+--------------------------------------------- Menial -Prof | -0.03565 -1.977 0.048 0.9650 0.6079 BlueCol -Prof | -0.03093 -2.147 0.032 0.9695 0.6494 Prof -Menial | 0.03565 1.977 0.048 1.0363 1.6449 Prof -BlueCol | 0.03093 2.147 0.032 1.0314 1.5400 ---------------------------------------------------------------- . . // * Section 6.2.3: predicting perfectly (example not in book) . . use ordwarm2, clear (77 & 89 General Social Survey) . gen byte dprst = (prst<20 & warm==1) . tab dprst warm, miss | Mom can have warm relations with child dprst | SD D A SA | Total -----------+--------------------------------------------+---------- 0 | 257 723 856 417 | 2,253 1 | 40 0 0 0 | 40 -----------+--------------------------------------------+---------- Total | 297 723 856 417 | 2,293 . mlogit warm yr89 male white age ed dprst, nolog Multinomial logistic regression Number of obs = 2293 LR chi2(18) = 491.02 Prob > chi2 = 0.0000 Log likelihood = -2750.2596 Pseudo R2 = 0.0820 ------------------------------------------------------------------------------ warm | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- SD | yr89 | -1.172053 .1752147 -6.69 0.000 -1.515468 -.828639 male | .3330375 .147681 2.26 0.024 .0435881 .6224868 white | .7984329 .2878503 2.77 0.006 .2342566 1.362609 age | .0258807 .004591 5.64 0.000 .0168825 .0348789 ed | -.0916641 .0247391 -3.71 0.000 -.1401517 -.0431764 dprst | 34.61727 2867906 0.00 1.000 -5620958 5621027 _cons | -1.820889 .4717513 -3.86 0.000 -2.745504 -.896273 -------------+---------------------------------------------------------------- D | yr89 | -.3645962 .1068134 -3.41 0.001 -.5739466 -.1552458 male | .4435216 .1041385 4.26 0.000 .2394138 .6476294 white | .0811686 .1617026 0.50 0.616 -.2357628 .3980999 age | .020822 .0032519 6.40 0.000 .0144483 .0271957 ed | -.0485043 .0175598 -2.76 0.006 -.0829208 -.0140878 dprst | -.287933 4450163 -0.00 1.000 -8722160 8722160 _cons | -.6614626 .3125173 -2.12 0.034 -1.273985 -.0489399 -------------+---------------------------------------------------------------- SA | yr89 | .0643419 .1229603 0.52 0.601 -.1766559 .3053397 male | -.8680532 .1311605 -6.62 0.000 -1.125123 -.6109834 white | -.295786 .1707618 -1.73 0.083 -.630473 .0389009 age | -.0063673 .0040262 -1.58 0.114 -.0142585 .0015238 ed | .0397509 .0220881 1.80 0.072 -.0035409 .0830427 dprst | .2806629 4696900 0.00 1.000 -9205754 9205755 _cons | -.4249334 .3742457 -1.14 0.256 -1.158441 .3085747 ------------------------------------------------------------------------------ (Outcome warm==A is the comparison group) . drop if dprst==1 (40 observations deleted) . mlogit warm yr89 male white age ed, nolog Multinomial logistic regression Number of obs = 2253 LR chi2(15) = 322.57 Prob > chi2 = 0.0000 Log likelihood = -2750.2596 Pseudo R2 = 0.0554 ------------------------------------------------------------------------------ warm | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- SD | yr89 | -1.172053 .1752146 -6.69 0.000 -1.515468 -.828639 male | .3330375 .147681 2.26 0.024 .0435881 .6224868 white | .7984329 .2878503 2.77 0.006 .2342566 1.362609 age | .0258807 .004591 5.64 0.000 .0168825 .0348789 ed | -.0916641 .0247391 -3.71 0.000 -.1401517 -.0431764 _cons | -1.820889 .4717513 -3.86 0.000 -2.745504 -.896273 -------------+---------------------------------------------------------------- D | yr89 | -.3645962 .1068134 -3.41 0.001 -.5739466 -.1552458 male | .4435216 .1041385 4.26 0.000 .2394138 .6476294 white | .0811686 .1617026 0.50 0.616 -.2357628 .3980999 age | .020822 .0032519 6.40 0.000 .0144483 .0271957 ed | -.0485043 .0175598 -2.76 0.006 -.0829208 -.0140878 _cons | -.6614626 .3125173 -2.12 0.034 -1.273985 -.0489399 -------------+---------------------------------------------------------------- SA | yr89 | .0643419 .1229603 0.52 0.601 -.1766559 .3053397 male | -.8680532 .1311605 -6.62 0.000 -1.125123 -.6109834 white | -.295786 .1707618 -1.73 0.083 -.630473 .0389009 age | -.0063673 .0040262 -1.58 0.114 -.0142585 .0015238 ed | .0397509 .0220881 1.80 0.072 -.0035409 .0830427 _cons | -.4249334 .3742457 -1.14 0.256 -1.158441 .3085747 ------------------------------------------------------------------------------ (Outcome warm==A is the comparison group) . . // * Section 6.3.2: testing the effects of the independent variables . . * LR tests of single coefficient using -lrtest- . use nomocc2, clear (1982 General Social Survey) . mlogit occ white ed exper, basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . estimates store fmodel . * test of white . quietly mlogit occ ed exper, basecategory(5) nolog . estimates store nmodel_white . lrtest fmodel nmodel_white likelihood-ratio test LR chi2(4) = 8.10 (Assumption: nmodel_white nested in fmodel) Prob > chi2 = 0.0881 . * test of ed . quietly mlogit occ white exper, basecategory(5) nolog . estimates store nmodel_ed . lrtest fmodel nmodel_ed likelihood-ratio test LR chi2(4) = 156.94 (Assumption: nmodel_ed nested in fmodel) Prob > chi2 = 0.0000 . * test of exper . quietly mlogit occ white ed, basecategory(5) nolog . estimates store nmodel_exper . lrtest fmodel nmodel_exper likelihood-ratio test LR chi2(4) = 8.56 (Assumption: nmodel_exper nested in fmodel) Prob > chi2 = 0.0731 . * tests using -mlogtest- . quietly mlogit occ white ed exper, basecategory(5) nolog . mlogtest, lr **** Likelihood-ratio tests for independent variables Ho: All coefficients associated with given variable(s) are 0. occ | chi2 df P>chi2 -------------+------------------------- white | 8.095 4 0.088 ed | 156.937 4 0.000 exper | 8.561 4 0.073 --------------------------------------- . . * Wald tests of single variable using -test- . quietly mlogit occ white ed exper, basecategory(5) nolog . test white ( 1) [Menial]white = 0 ( 2) [BlueCol]white = 0 ( 3) [Craft]white = 0 ( 4) [WhiteCol]white = 0 chi2( 4) = 8.15 Prob > chi2 = 0.0863 . test ed ( 1) [Menial]ed = 0 ( 2) [BlueCol]ed = 0 ( 3) [Craft]ed = 0 ( 4) [WhiteCol]ed = 0 chi2( 4) = 84.97 Prob > chi2 = 0.0000 . test exper ( 1) [Menial]exper = 0 ( 2) [BlueCol]exper = 0 ( 3) [Craft]exper = 0 ( 4) [WhiteCol]exper = 0 chi2( 4) = 7.99 Prob > chi2 = 0.0918 . * tests using -mlogtest- . mlogtest, wald **** Wald tests for independent variables Ho: All coefficients associated with given variable(s) are 0. occ | chi2 df P>chi2 -------------+------------------------- white | 8.149 4 0.086 ed | 84.968 4 0.000 exper | 7.995 4 0.092 --------------------------------------- . . * LR test of multiple variables using -lrtest- . mlogit occ white ed exper, basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . estimates store fmodel . mlogit occ white, basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(4) = 5.31 Prob > chi2 = 0.2566 Log likelihood = -507.18706 Pseudo R2 = 0.0052 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.059392 .625174 -1.69 0.090 -2.28471 .1659269 _cons | -.3364722 .58554 -0.57 0.566 -1.48411 .8111652 -------------+---------------------------------------------------------------- BlueCol | white | .0800427 .6463479 0.12 0.901 -1.186776 1.346861 _cons | -.5596158 .6267832 -0.89 0.372 -1.788088 .6688567 -------------+---------------------------------------------------------------- Craft | white | -.7065702 .5156496 -1.37 0.171 -1.717225 .3040844 _cons | .3566749 .4928054 0.72 0.469 -.6092059 1.322556 -------------+---------------------------------------------------------------- WhiteCol | white | .2623643 .8234209 0.32 0.750 -1.351511 1.87624 _cons | -1.252763 .8017837 -1.56 0.118 -2.82423 .3187043 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . estimates store nmodel . lrtest fmodel nmodel likelihood-ratio test LR chi2(8) = 160.77 (Assumption: nmodel nested in fmodel) Prob > chi2 = 0.0000 . * test using -mlogtest- . mlogit occ white ed exper, basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . mlogtest, lr set(ed exper) **** Likelihood-ratio tests for independent variables Ho: All coefficients associated with given variable(s) are 0. occ | chi2 df P>chi2 -------------+------------------------- white | 8.095 4 0.088 ed | 156.937 4 0.000 exper | 8.561 4 0.073 -------------+------------------------- set_1: | 160.773 8 0.000 ed | exper | --------------------------------------- . . * Wald test of multiple variables with -test- . mlogit occ white ed exper, basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . test ed exper ( 1) [Menial]ed = 0 ( 2) [BlueCol]ed = 0 ( 3) [Craft]ed = 0 ( 4) [WhiteCol]ed = 0 ( 5) [Menial]exper = 0 ( 6) [BlueCol]exper = 0 ( 7) [Craft]exper = 0 ( 8) [WhiteCol]exper = 0 chi2( 8) = 88.18 Prob > chi2 = 0.0000 . * test using -mlogtest- . mlogit occ white ed exper, basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . mlogtest, wald set(ed exper) **** Wald tests for independent variables Ho: All coefficients associated with given variable(s) are 0. occ | chi2 df P>chi2 -------------+------------------------- white | 8.149 4 0.086 ed | 84.968 4 0.000 exper | 7.995 4 0.092 -------------+------------------------- set_1: | 88.176 8 0.000 ed | exper | --------------------------------------- . . // * Section 6.3.3: tests for combining dependent categories . . * Wald test of combining categories using -test- . mlogit occ white ed exper, basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . mlogtest, combine **** Wald tests for combining outcome categories Ho: All coefficients except intercepts associated with given pair of outcomes are 0 (i.e., categories can be collapsed). Categories tested | chi2 df P>chi2 ------------------+------------------------ Menial- BlueCol | 3.994 3 0.262 Menial- Craft | 3.203 3 0.361 Menial-WhiteCol | 11.951 3 0.008 Menial- Prof | 48.190 3 0.000 BlueCol- Craft | 8.441 3 0.038 BlueCol-WhiteCol | 20.055 3 0.000 BlueCol- Prof | 76.393 3 0.000 Craft-WhiteCol | 8.892 3 0.031 Craft- Prof | 60.583 3 0.000 WhiteCol- Prof | 22.203 3 0.000 ------------------------------------------- . test [Menial] ( 1) [Menial]white = 0 ( 2) [Menial]ed = 0 ( 3) [Menial]exper = 0 chi2( 3) = 48.19 Prob > chi2 = 0.0000 . test [Menial=Craft] ( 1) [Menial]white - [Craft]white = 0 ( 2) [Menial]ed - [Craft]ed = 0 ( 3) [Menial]exper - [Craft]exper = 0 chi2( 3) = 3.20 Prob > chi2 = 0.3614 . . * LR test of combining categories using -mlogtest- . mlogit occ white ed exper, basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . mlogtest, lrcomb **** LR tests for combining outcome categories Ho: All coefficients except intercepts associated with given pair of outcomes are 0 (i.e., categories can be collapsed). Categories tested | chi2 df P>chi2 ------------------+------------------------ Menial- BlueCol | 4.095 3 0.251 Menial- Craft | 3.376 3 0.337 Menial-WhiteCol | 13.223 3 0.004 Menial- Prof | 64.607 3 0.000 BlueCol- Craft | 9.176 3 0.027 BlueCol-WhiteCol | 22.803 3 0.000 BlueCol- Prof | 125.699 3 0.000 Craft-WhiteCol | 9.992 3 0.019 Craft- Prof | 95.889 3 0.000 WhiteCol- Prof | 26.736 3 0.000 ------------------------------------------- . * example of the constraint imposed by -mlogtest- . mlogit occ white ed exper, nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . estimates store fmodel . constraint define 999 [Menial] . mlogit occ exper ed white, base(2) constraint(999) nolog Multinomial logistic regression Number of obs = 337 LR chi2(9) = 161.99 Prob > chi2 = 0.0000 Log likelihood = -428.84791 Pseudo R2 = 0.1589 ( 1) [Menial]exper = 0 ( 2) [Menial]ed = 0 ( 3) [Menial]white = 0 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | exper | (dropped) ed | (dropped) white | (dropped) _cons | -.8001193 .2162194 -3.70 0.000 -1.223901 -.3763371 -------------+---------------------------------------------------------------- Craft | exper | .0242824 .0113959 2.13 0.033 .0019469 .0466179 ed | .1599345 .0693853 2.31 0.021 .0239418 .2959273 white | -.2381783 .4978563 -0.48 0.632 -1.213959 .7376021 _cons | -1.969087 1.054935 -1.87 0.062 -4.036721 .098547 -------------+---------------------------------------------------------------- WhiteCol | exper | .0312007 .0143598 2.17 0.030 .0030561 .0593454 ed | .4195709 .0958978 4.38 0.000 .2316147 .607527 white | .8829927 .843371 1.05 0.295 -.7699841 2.535969 _cons | -7.140306 1.623401 -4.40 0.000 -10.32211 -3.958498 -------------+---------------------------------------------------------------- Prof | exper | .032303 .0133779 2.41 0.016 .0060827 .0585233 ed | .8445092 .093709 9.01 0.000 .6608429 1.028176 white | 1.097459 .6877939 1.60 0.111 -.2505923 2.44551 _cons | -12.42143 1.569897 -7.91 0.000 -15.49837 -9.344489 ------------------------------------------------------------------------------ (Outcome occ==BlueCol is the comparison group) . estimates store nmodel . lrtest fmodel nmodel likelihood-ratio test LR chi2(3) = 4.09 (Assumption: nmodel nested in fmodel) Prob > chi2 = 0.2514 . . // * Section 6.4: independence of irrelevant alternatives . . * Hausman test of iia . mlogit occ white ed exper, basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . mlogtest, hausman base **** Hausman tests of IIA assumption Ho: Odds(Outcome-J vs Outcome-K) are independent of other alternatives. Omitted | chi2 df P>chi2 evidence ---------+------------------------------------ Menial | 7.324 12 0.835 for Ho BlueCol | 0.320 12 1.000 for Ho Craft | -14.436 12 1.000 for Ho WhiteCol | -5.541 11 1.000 for Ho Prof | -0.119 12 1.000 for Ho ---------------------------------------------- . * example using alternative outcomes (not in book) . quietly mlogit occ white ed exper, basecategory(1) nolog . mlogtest, hausman base **** Hausman tests of IIA assumption Ho: Odds(Outcome-J vs Outcome-K) are independent of other alternatives. Omitted | chi2 df P>chi2 evidence ---------+------------------------------------ BlueCol | 0.333 12 1.000 for Ho Craft | -14.436 12 1.000 for Ho WhiteCol | -7.764 12 1.000 for Ho Prof | -0.119 12 1.000 for Ho Menial | 7.324 12 0.835 for Ho ---------------------------------------------- . quietly mlogit occ white ed exper, basecategory(2) nolog . mlogtest, hausman base **** Hausman tests of IIA assumption Ho: Odds(Outcome-J vs Outcome-K) are independent of other alternatives. Omitted | chi2 df P>chi2 evidence ---------+------------------------------------ Menial | 7.324 12 0.835 for Ho Craft | -14.436 12 1.000 for Ho WhiteCol | -7.764 12 1.000 for Ho Prof | -0.119 12 1.000 for Ho BlueCol | 0.320 12 1.000 for Ho ---------------------------------------------- . quietly mlogit occ white ed exper, basecategory(3) nolog . mlogtest, hausman base **** Hausman tests of IIA assumption Ho: Odds(Outcome-J vs Outcome-K) are independent of other alternatives. Omitted | chi2 df P>chi2 evidence ---------+------------------------------------ Menial | 7.324 12 0.835 for Ho BlueCol | 0.333 12 1.000 for Ho WhiteCol | -7.764 12 1.000 for Ho Prof | -0.119 12 1.000 for Ho Craft | -14.436 12 1.000 for Ho ---------------------------------------------- . quietly mlogit occ white ed exper, basecategory(4) nolog . mlogtest, hausman base **** Hausman tests of IIA assumption Ho: Odds(Outcome-J vs Outcome-K) are independent of other alternatives. Omitted | chi2 df P>chi2 evidence ---------+------------------------------------ Menial | 7.324 12 0.835 for Ho BlueCol | 0.320 12 1.000 for Ho Craft | -14.436 12 1.000 for Ho Prof | -0.119 12 1.000 for Ho WhiteCol | -5.541 11 1.000 for Ho ---------------------------------------------- . . * Small-Hsiao test of iia . quietly mlogit occ white ed exper, basecategory(5) nolog . set seed 339487731 . mlogtest, smhsiao **** Small-Hsiao tests of IIA assumption Ho: Odds(Outcome-J vs Outcome-K) are independent of other alternatives. Omitted | lnL(full) lnL(omit) chi2 df P>chi2 evidence ---------+--------------------------------------------------------- Menial | -182.140 -169.907 24.466 4 0.000 against Ho BlueCol | -148.711 -140.054 17.315 4 0.002 against Ho Craft | -131.801 -119.286 25.030 4 0.000 against Ho WhiteCol | -161.436 -148.550 25.772 4 0.000 against Ho ------------------------------------------------------------------- . set seed 8675309 . mlogtest, smhsiao **** Small-Hsiao tests of IIA assumption Ho: Odds(Outcome-J vs Outcome-K) are independent of other alternatives. Omitted | lnL(full) lnL(omit) chi2 df P>chi2 evidence ---------+--------------------------------------------------------- Menial | -169.785 -161.523 16.523 4 0.002 against Ho BlueCol | -131.900 -125.871 12.058 4 0.017 against Ho Craft | -136.934 -129.905 14.058 4 0.007 against Ho WhiteCol | -155.364 -150.239 10.250 4 0.036 against Ho ------------------------------------------------------------------- . . // * Section 6.6.2: in sample predicted probabilities with -predict- . . * estimate model and compute predictions . mlogit occ white ed exper, basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . predict ProbM ProbB ProbC ProbW ProbP (option p assumed; predicted probabilities) . desc Prob* storage display value variable name type format label variable label ------------------------------------------------------------------------------- ProbM float %9.0g Pr(occ==1) ProbB float %9.0g Pr(occ==2) ProbC float %9.0g Pr(occ==3) ProbW float %9.0g Pr(occ==4) ProbP float %9.0g Pr(occ==5) . sum Prob* Variable | Obs Mean Std. Dev. Min Max -------------+-------------------------------------------------------- ProbM | 337 .0919881 .059396 .0010737 .3281906 ProbB | 337 .2047478 .1450568 .0012066 .6974148 ProbC | 337 .2492582 .1161309 .0079713 .551609 ProbW | 337 .1216617 .0452844 .0083857 .2300058 ProbP | 337 .3323442 .2870992 .0001935 .9597512 . . * using -predict- to compare -mlogit- and -ologit- . use ordwarm2,clear (77 & 89 General Social Survey) . ologit warm yr89 male white age ed prst, nolog Ordered logit estimates Number of obs = 2293 LR chi2(6) = 301.72 Prob > chi2 = 0.0000 Log likelihood = -2844.9123 Pseudo R2 = 0.0504 ------------------------------------------------------------------------------ warm | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- yr89 | .5239025 .0798988 6.56 0.000 .3673037 .6805013 male | -.7332997 .0784827 -9.34 0.000 -.8871229 -.5794766 white | -.3911595 .1183808 -3.30 0.001 -.6231815 -.1591374 age | -.0216655 .0024683 -8.78 0.000 -.0265032 -.0168278 ed | .0671728 .015975 4.20 0.000 .0358624 .0984831 prst | .0060727 .0032929 1.84 0.065 -.0003813 .0125267 -------------+---------------------------------------------------------------- _cut1 | -2.465362 .2389126 (Ancillary parameters) _cut2 | -.630904 .2333155 _cut3 | 1.261854 .2340179 ------------------------------------------------------------------------------ . predict SDologit Dologit Aologit SAologit (option p assumed; predicted probabilities) . label var Dologit "ologit-D" . mlogit warm yr89 male white age ed prst, nolog Multinomial logistic regression Number of obs = 2293 LR chi2(18) = 349.54 Prob > chi2 = 0.0000 Log likelihood = -2820.9982 Pseudo R2 = 0.0583 ------------------------------------------------------------------------------ warm | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- SD | yr89 | -1.097643 .1637 -6.71 0.000 -1.418489 -.7767971 male | .3597704 .1411255 2.55 0.011 .0831696 .6363713 white | .5339852 .2463276 2.17 0.030 .0511919 1.016778 age | .0250045 .0044826 5.58 0.000 .0162188 .0337901 ed | -.1105661 .0280302 -3.94 0.000 -.1655043 -.0556279 prst | -.0024333 .0061387 -0.40 0.692 -.0144649 .0095983 _cons | -1.115396 .4303341 -2.59 0.010 -1.958835 -.2719563 -------------+---------------------------------------------------------------- D | yr89 | -.3630178 .1069194 -3.40 0.001 -.572576 -.1534596 male | .4600329 .1044742 4.40 0.000 .2552672 .6647985 white | .1123935 .1622593 0.69 0.489 -.2056289 .430416 age | .0225556 .0033222 6.79 0.000 .0160441 .0290671 ed | -.0183148 .021324 -0.86 0.390 -.060109 .0234794 prst | -.0112995 .0044187 -2.56 0.011 -.01996 -.0026389 _cons | -.7020634 .3124924 -2.25 0.025 -1.314537 -.0895896 -------------+---------------------------------------------------------------- SA | yr89 | .0625534 .1228908 0.51 0.611 -.1783082 .3034149 male | -.8666833 .1310965 -6.61 0.000 -1.123628 -.6097389 white | -.3002409 .1710551 -1.76 0.079 -.6355028 .0350211 age | -.0066719 .0041053 -1.63 0.104 -.0147181 .0013744 ed | .0330137 .0274376 1.20 0.229 -.020763 .0867904 prst | .0017323 .0052199 0.33 0.740 -.0084985 .0119631 _cons | -.3932277 .3740361 -1.05 0.293 -1.126325 .3398697 ------------------------------------------------------------------------------ (Outcome warm==A is the comparison group) . predict SDmlogit Dmlogit Amlogit SAmlogit (option p assumed; predicted probabilities) . label var Dmlogit "mlogit-D" . dotplot Dologit Dmlogit, ylabel(0(.25).75) /// > ysize(2.0254) xsize(3.0381) . graph export 06omlogdot.eps, replace (file 06omlogdot.eps written in .eps format) . . * another interesting way to compare the predictions (not in book) . corr SDologit SDmlogit (obs=2293) | SDologit SDmlogit -------------+------------------ SDologit | 1.0000 SDmlogit | 0.9013 1.0000 . corr Dologit Dmlogit (obs=2293) | Dologit Dmlogit -------------+------------------ Dologit | 1.0000 Dmlogit | 0.9239 1.0000 . corr Aologit Amlogit (obs=2293) | Aologit Amlogit -------------+------------------ Aologit | 1.0000 Amlogit | 0.8593 1.0000 . corr SAologit SAmlogit (obs=2293) | SAologit SAmlogit -------------+------------------ SAologit | 1.0000 SAmlogit | 0.9469 1.0000 . graph twoway scatter Dologit Dmlogit, /// > xtitle("mlogit: Pr(y=Disagree)") /// > ytitle("ologit: Pr(y=Disagree)") /// > ylabel(0(.25).75) xlabel(0(.25).75) sort . graph export omloggraph.eps, replace (file omloggraph.eps written in .eps format) . . // * Section 6.6.3: individual predicted probabilities with -prvalue- . . use nomocc2, clear (1982 General Social Survey) . mlogit occ white ed exper, basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . quietly prvalue, x(white=0) rest(mean) save . prvalue, x(white=1) rest(mean) dif mlogit: Change in Predictions for occ Predicted probabilities for each category: Current Saved Difference Pr(y=Menial|x): 0.0860 0.2168 -0.1309 Pr(y=BlueCol|x): 0.1862 0.1363 0.0498 Pr(y=Craft|x): 0.2790 0.4387 -0.1597 Pr(y=WhiteCol|x): 0.1674 0.0877 0.0797 Pr(y=Prof|x): 0.2814 0.1204 0.1611 white ed exper Current= 1 13.094955 20.501484 Saved= 0 13.094955 20.501484 Diff= 1 0 0 . . // * Section 6.6.4: tables of predicted probabilities with -prtab- . . label def lwhite 0 NonWhite 1 White . label val white lwhite . prtab ed white, novarlbl outcome(1) mlogit: Predicted probabilities of outcome 1 (Menial) for occ ------------------------------ | white ed | NonWhite White ----------+------------------- 3 | 0.2847 0.1216 6 | 0.2987 0.1384 7 | 0.2988 0.1417 8 | 0.2963 0.1431 9 | 0.2906 0.1417 10 | 0.2814 0.1366 11 | 0.2675 0.1265 12 | 0.2476 0.1104 13 | 0.2199 0.0883 14 | 0.1832 0.0632 15 | 0.1393 0.0401 16 | 0.0944 0.0228 17 | 0.0569 0.0120 18 | 0.0310 0.0060 19 | 0.0158 0.0029 20 | 0.0077 0.0014 ------------------------------ white ed exper x= .91691395 13.094955 20.501484 . . // * Section 6.6.5: graphing predicted probabilities with -prgen- . . * plotting probabilities to compare two groups . quietly mlogit occ white ed exper, basecategory(5) . prgen ed, x(white=1) from(6) to(20) generate(wht) ncases(15) mlogit: Predicted values as ed varies from 6 to 20. white ed exper x= 1 13.094955 20.501484 . desc wht* storage display value variable name type format label variable label ------------------------------------------------------------------------------- whtx float %9.0g Changing value of ed whtp1 float %9.0g pr(Menial) [1] whts1 float %9.0g pr(y<=1) whtp2 float %9.0g pr(BlueCol) [2] whts2 float %9.0g pr(y<=2) whtp3 float %9.0g pr(Craft) [3] whts3 float %9.0g pr(y<=3) whtp4 float %9.0g pr(WhiteCol) [4] whts4 float %9.0g pr(y<=4) whtp5 float %9.0g pr(Prof) [5] whts5 float %9.0g pr(y<=5) . prgen ed, x(white=0) from(6) to(20) generate(nwht) ncases(15) mlogit: Predicted values as ed varies from 6 to 20. white ed exper x= 0 13.094955 20.501484 . desc nwht* storage display value variable name type format label variable label ------------------------------------------------------------------------------- nwhtx float %9.0g Changing value of ed nwhtp1 float %9.0g pr(Menial) [1] nwhts1 float %9.0g pr(y<=1) nwhtp2 float %9.0g pr(BlueCol) [2] nwhts2 float %9.0g pr(y<=2) nwhtp3 float %9.0g pr(Craft) [3] nwhts3 float %9.0g pr(y<=3) nwhtp4 float %9.0g pr(WhiteCol) [4] nwhts4 float %9.0g pr(y<=4) nwhtp5 float %9.0g pr(Prof) [5] nwhts5 float %9.0g pr(y<=5) . label var whtp1 "Whites" . label var nwhtp1 "Nonwhites" . graph twoway connected whtp1 nwhtp1 nwhtx, /// > xtitle("Years of Education") /// > ytitle("Pr(Menial Job)") /// > ylabel(0(.25).50) xlabel(6 8 12 16 20) /// > ysize(2.7051) xsize(4.0421) . graph export 06prmenial.eps, replace (file 06prmenial.eps written in .eps format) . . * plotting probabilities for all outcomes for one group . label var whts1 "Menial" . label var whts2 "Blue Collar" . label var whts3 "Craft" . label var whts4 "White Collar" . graph twoway connected whts1 whts2 whts3 whts4 whtx, /// > xtitle("Whites: Years of Education") /// > ytitle("Summed Probability") /// > xlabel(6(2)20) /// > ylabel(0(.25)1) /// > ysize(2.6195) xsize(4.0421) . graph export 06prsum.eps, replace (file 06prsum.eps written in .eps format) . . gen zero = 0 . gen one = 1 . graph twoway (rarea zero whts1 whtx, bc(gs1)) /// > (rarea whts1 whts2 whtx, bc(gs4)) /// > (rarea whts2 whts3 whtx, bc(gs8)) /// > (rarea whts3 whts4 whtx, bc(gs11)) /// > (rarea whts4 one whtx, bc(gs14)), /// > ytitle("Summed Probability") /// > legend( order( 1 2 3 4 5) /// > label( 1 "Menial") /// > label( 2 "Blue Collar") label( 3 "Craft") /// > label(4 "White Collar") label(5 "Professional")) /// > xtitle("Whites: Years of Education") /// > xlabel(6 8 12 16 20) ylabel(0(.25)1) /// > ysize(2.6195) xsize(4.0421) /// > plotregion(margin(zero)) . graph export 06prsumrevised.eps, replace (file 06prsumrevised.eps written in .eps format) . . // * Section 6.6.6: changes in predicted probabilities . . mlogit occ white ed exper, basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . * prchange . prchange mlogit: Changes in Predicted Probabilities for occ white Avg|Chg| Menial BlueCol Craft WhiteCol Prof 0->1 .11623582 -.13085523 .04981799 -.15973434 .07971004 .1610615 ed Avg|Chg| Menial BlueCol Craft WhiteCol Prof Min->Max .39242268 -.13017954 -.70077323 -.15010394 .02425591 .95680079 -+1/2 .05855425 -.02559762 -.06831616 -.05247185 .01250795 .13387768 -+sd/2 .1640657 -.07129153 -.19310513 -.14576758 .03064777 .37951647 MargEfct .05894859 -.02579097 -.06870635 -.05287415 .01282041 .13455107 exper Avg|Chg| Menial BlueCol Craft WhiteCol Prof Min->Max .12193559 -.11536534 -.18947365 .03115708 .09478889 .17889298 -+1/2 .00233425 -.00226997 -.00356567 .00105992 .0016944 .00308132 -+sd/2 .03253578 -.03167491 -.04966453 .01479983 .02360725 .04293236 MargEfct .00233427 -.00226997 -.00356571 .00105992 .00169442 .00308134 Menial BlueCol Craft WhiteCol Prof Pr(y|x) .09426806 .18419114 .29411051 .16112968 .26630062 white ed exper x= .916914 13.095 20.5015 sd(x)= .276423 2.94643 13.9594 . * mfx compute: patience, this can take a long time! . mfx compute, predict(outcome(1)) Marginal effects after mlogit y = Pr(occ==1) (predict, outcome(1)) = .09426806 ------------------------------------------------------------------------------ variable | dy/dx Std. Err. z P>|z| [ 95% C.I. ] X ---------+-------------------------------------------------------------------- white*| -.1308552 .08915 -1.47 0.142 -.305592 .043882 .916914 ed | -.025791 .00688 -3.75 0.000 -.039269 -.012312 13.095 exper | -.00227 .00126 -1.80 0.071 -.004737 .000197 20.5015 ------------------------------------------------------------------------------ (*) dy/dx is for discrete change of dummy variable from 0 to 1 . . // * Section 6.6.7: plotting discrete changes with mlogview . * Examples do not use -mlogview- since -mlogview- cannot automatically . * reproduce graphs in do files; instead we use -mlogplot- . . mlogplot, std(0uu) p(.1) dc ntics(9) . mlogplot, std(0ss) p(.1) min(-.2) max(.4) dc ntics(7) . . // * Section 6.6.8: odds ratios using -listcoef- and -mlogview- . . * plot hypothetical values: relative to A . matrix mnlbeta = (-.693, .693, .347 \ .347, -.347, .693 ) . matrix mnlsd = (1, 2, 4) . global mnlname = "x1 x2 x3" . global mnlcatnm = "B C A" . global mnldepnm "depvar" . mlogplot, matrix std(uuu) vars(x1 x2 x3) packed . graph export 06orploteg.eps, replace (file 06orploteg.eps written in .eps format) . . * plot hypothetical values: relative to B . matrix mnlbeta = (-.693, .693, .347 \ .347, -.347, .693 ) . matrix mnlsd = (1, 2, 4) . global mnlname = "x1 x2 x3" . global mnlcatnm = "B C A" . global mnldepnm "depvar" . * note: use base(1) since B is the first letter in -mnlcatnm- . mlogplot, matrix std(uuu) vars(x1 x2 x3) packed base(1) . graph export 06orplotegb.eps, replace (file 06orplotegb.eps written in .eps format) . . * plot odds ratios from occupational outcomes example . mlogit occ white ed exper,basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . listcoef white, help mlogit (N=337): Factor Change in the Odds of occ Variable: white (sd= .28) Odds comparing| Group 1 vs Group 2| b z P>|z| e^b e^bStdX ------------------+--------------------------------------------- Menial -BlueCol | -1.23650 -1.707 0.088 0.2904 0.7105 Menial -Craft | -0.47234 -0.782 0.434 0.6235 0.8776 Menial -WhiteCol | -1.57139 -1.741 0.082 0.2078 0.6477 Menial -Prof | -1.77431 -2.350 0.019 0.1696 0.6123 BlueCol -Menial | 1.23650 1.707 0.088 3.4436 1.4075 BlueCol -Craft | 0.76416 1.208 0.227 2.1472 1.2352 BlueCol -WhiteCol | -0.33488 -0.359 0.720 0.7154 0.9116 BlueCol -Prof | -0.53780 -0.673 0.501 0.5840 0.8619 Craft -Menial | 0.47234 0.782 0.434 1.6037 1.1395 Craft -BlueCol | -0.76416 -1.208 0.227 0.4657 0.8096 Craft -WhiteCol | -1.09904 -1.343 0.179 0.3332 0.7380 Craft -Prof | -1.30196 -2.011 0.044 0.2720 0.6978 WhiteCol-Menial | 1.57139 1.741 0.082 4.8133 1.5440 WhiteCol-BlueCol | 0.33488 0.359 0.720 1.3978 1.0970 WhiteCol-Craft | 1.09904 1.343 0.179 3.0013 1.3550 WhiteCol-Prof | -0.20292 -0.233 0.815 0.8163 0.9455 Prof -Menial | 1.77431 2.350 0.019 5.8962 1.6331 Prof -BlueCol | 0.53780 0.673 0.501 1.7122 1.1603 Prof -Craft | 1.30196 2.011 0.044 3.6765 1.4332 Prof -WhiteCol | 0.20292 0.233 0.815 1.2250 1.0577 ---------------------------------------------------------------- b = raw coefficient z = z-score for test of b=0 P>|z| = p-value for z-test e^b = exp(b) = factor change in odds for unit increase in X e^bStdX = exp(b*SD of X) = change in odds for SD increase in X . * or plot without significance levels . mlogplot white ed exper, std(0ss) b(5) p(1) min(-2.75) max(.55) or /// > packed ntics(7) . graph export 06orplotocc1.eps,replace (file 06orplotocc1.eps written in .eps format) . . * or plot with significance levels . mlogplot white ed exper, prob(.1) std(0ss) b(5) min(-2.75) max(.55) /// > or ntics(7) . graph export 06orplotocc2.eps, replace (file 06orplotocc2.eps written in .eps format) . * or plot with significance levels and discrete change . prchange mlogit: Changes in Predicted Probabilities for occ white Avg|Chg| Menial BlueCol Craft WhiteCol Prof 0->1 .11623582 -.13085523 .04981799 -.15973434 .07971004 .1610615 ed Avg|Chg| Menial BlueCol Craft WhiteCol Prof Min->Max .39242268 -.13017954 -.70077323 -.15010394 .02425591 .95680079 -+1/2 .05855425 -.02559762 -.06831616 -.05247185 .01250795 .13387768 -+sd/2 .1640657 -.07129153 -.19310513 -.14576758 .03064777 .37951647 MargEfct .05894859 -.02579097 -.06870635 -.05287415 .01282041 .13455107 exper Avg|Chg| Menial BlueCol Craft WhiteCol Prof Min->Max .12193559 -.11536534 -.18947365 .03115708 .09478889 .17889298 -+1/2 .00233425 -.00226997 -.00356567 .00105992 .0016944 .00308132 -+sd/2 .03253578 -.03167491 -.04966453 .01479983 .02360725 .04293236 MargEfct .00233427 -.00226997 -.00356571 .00105992 .00169442 .00308134 Menial BlueCol Craft WhiteCol Prof Pr(y|x) .09426806 .18419114 .29411051 .16112968 .26630062 white ed exper x= .916914 13.095 20.5015 sd(x)= .276423 2.94643 13.9594 . mlogplot white ed exper, prob(.1) std(0ss) b(5) min(-2.75) max(.55) /// > dc or ntics(7) . graph export 06orplotocc3.eps, replace (file 06orplotocc3.eps written in .eps format) . . // Section 6.6.9: using -mlogplot- . . * or plot using -mlogplot- . mlogit occ white ed exper, basecategory(5) nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . prchange mlogit: Changes in Predicted Probabilities for occ white Avg|Chg| Menial BlueCol Craft WhiteCol Prof 0->1 .11623582 -.13085523 .04981799 -.15973434 .07971004 .1610615 ed Avg|Chg| Menial BlueCol Craft WhiteCol Prof Min->Max .39242268 -.13017954 -.70077323 -.15010394 .02425591 .95680079 -+1/2 .05855425 -.02559762 -.06831616 -.05247185 .01250795 .13387768 -+sd/2 .1640657 -.07129153 -.19310513 -.14576758 .03064777 .37951647 MargEfct .05894859 -.02579097 -.06870635 -.05287415 .01282041 .13455107 exper Avg|Chg| Menial BlueCol Craft WhiteCol Prof Min->Max .12193559 -.11536534 -.18947365 .03115708 .09478889 .17889298 -+1/2 .00233425 -.00226997 -.00356567 .00105992 .0016944 .00308132 -+sd/2 .03253578 -.03167491 -.04966453 .01479983 .02360725 .04293236 MargEfct .00233427 -.00226997 -.00356571 .00105992 .00169442 .00308134 Menial BlueCol Craft WhiteCol Prof Pr(y|x) .09426806 .18419114 .29411051 .16112968 .26630062 white ed exper x= .916914 13.095 20.5015 sd(x)= .276423 2.94643 13.9594 . mlogplot white ed exper, std(0ss) p(.1) min(-2.75) max(.55) or ntics(7) . . * other examples using -mlogplot- (not in book) . mlogplot white ed exper, std(0ss) p(.1) min(-2.75) max(.55) or dc ntics(7) . mlogplot white ed exper, dc std(0ss) min(-.5) max(.5) . mlogplot white ed exper, or std(0ss) min(-2.5) max(.5) . mlogplot white ed exper, or dc std(0ss) min(-.5) max(.5) . mlogplot white ed exper, dc or std(0ss) min(-2.5) max(.5) p(.1) . . // * Section 6.6.10: plotting estimates from matrices with -mlogplot- . . * plot example data . matrix mnlbeta = (-.693, .693, .347 \ .347, -.347, .693 ) . matrix mnlsd = (1, 2, 4) . global mnlname = "x1 x2 x3" . global mnlcatnm = "B C A" . global mnldepnm "depvar" . mlogplot, matrix std(uuu) vars(x1 x2 x3) packed . graph export 06matrix1.eps, replace (file 06matrix1.eps written in .eps format) . . * combining coefficients from two groups . * estimate two sets of coefficients . use nomocc2, clear (1982 General Social Survey) . mlogit occ ed exper if white==1, base(5) nolog Multinomial logistic regression Number of obs = 309 LR chi2(8) = 154.60 Prob > chi2 = 0.0000 Log likelihood = -388.21313 Pseudo R2 = 0.1660 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | ed | -.8307514 .1297238 -6.40 0.000 -1.085005 -.5764973 exper | -.0338038 .0192045 -1.76 0.078 -.071444 .0038364 _cons | 10.34842 1.779603 5.82 0.000 6.860465 13.83638 -------------+---------------------------------------------------------------- BlueCol | ed | -.9225522 .1085452 -8.50 0.000 -1.135297 -.7098075 exper | -.031449 .0150766 -2.09 0.037 -.0609987 -.0018994 _cons | 12.27337 1.507683 8.14 0.000 9.318368 15.22838 -------------+---------------------------------------------------------------- Craft | ed | -.6876114 .0952882 -7.22 0.000 -.8743729 -.50085 exper | -.0002589 .0131021 -0.02 0.984 -.0259385 .0254207 _cons | 9.017976 1.36333 6.61 0.000 6.345897 11.69005 -------------+---------------------------------------------------------------- WhiteCol | ed | -.4196403 .0956209 -4.39 0.000 -.6070539 -.2322268 exper | .0008478 .0147558 0.06 0.954 -.0280731 .0297687 _cons | 4.972973 1.421146 3.50 0.000 2.187578 7.758368 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . mlogit occ ed exper if white==0, base(5) nolog Multinomial logistic regression Number of obs = 28 LR chi2(8) = 17.79 Prob > chi2 = 0.0228 Log likelihood = -32.779416 Pseudo R2 = 0.2135 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | ed | -.7012628 .3331146 -2.11 0.035 -1.354155 -.0483701 exper | -.1108415 .0741488 -1.49 0.135 -.2561705 .0344876 _cons | 12.32779 6.053743 2.04 0.042 .4626714 24.19291 -------------+---------------------------------------------------------------- BlueCol | ed | -.560695 .3283292 -1.71 0.088 -1.204208 .0828185 exper | -.0261099 .0682348 -0.38 0.702 -.1598477 .1076279 _cons | 8.063397 6.008358 1.34 0.180 -3.712768 19.83956 -------------+---------------------------------------------------------------- Craft | ed | -.882502 .3359805 -2.63 0.009 -1.541012 -.2239924 exper | -.1597929 .0744172 -2.15 0.032 -.305648 -.0139378 _cons | 16.21925 6.059753 2.68 0.007 4.342356 28.09615 -------------+---------------------------------------------------------------- WhiteCol | ed | -.5311514 .369815 -1.44 0.151 -1.255976 .1936728 exper | -.0520881 .0838967 -0.62 0.535 -.2165227 .1123464 _cons | 7.821371 6.805367 1.15 0.250 -5.516904 21.15965 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . * save coefficients for ed to mnlbeta . matrix mnlbeta = /// > (-.8307514, -.9225522, -.6876114, -.4196403 \ /// > -.7012628, -.560695 , -.882502 , -.5311514 ) . * transpose to make columns correspond to variables . matrix mnlbeta = mnlbeta' . * compute sd of ed and add to matrix . sum ed Variable | Obs Mean Std. Dev. Min Max -------------+-------------------------------------------------------- ed | 337 13.09496 2.946427 3 20 . matrix mnlsd = (2.946427,2.946427) . global mnlname = "White NonWhite" . global mnlcatnm = "Menial BlueCol Craft WhiteCol Prof" . mlogplot, vars(White NonWhite) packed /// > or matrix std(ss) /// > note("Racial Differences in Effects of Education") . graph export 06matrix2.eps, replace (file 06matrix2.eps written in .eps format) . . // * Section 6.7.1: data arrangement for conditional logit . . use travel2.dta, clear (Greene & Hensher 1997 data on travel mode choice) . tab mode Mode of | transportat | ion | Freq. Percent Cum. ------------+----------------------------------- Train | 152 33.33 33.33 Bus | 152 33.33 66.67 Car | 152 33.33 100.00 ------------+----------------------------------- Total | 456 100.00 . list id mode train bus time invc choice in 1/6, sepby(id) +-------------------------------------------------+ | id mode train bus time invc choice | |-------------------------------------------------| 1. | 1 Train 1 0 406 31 0 | 2. | 1 Bus 0 1 452 25 0 | 3. | 1 Car 0 0 180 10 1 | |-------------------------------------------------| 4. | 2 Train 1 0 398 31 0 | 5. | 2 Bus 0 1 452 25 0 | 6. | 2 Car 0 0 255 11 1 | +-------------------------------------------------+ . list id mode train bus time invc choice in 16/18, nodisplay +-------------------------------------------------+ | id mode train bus time invc choice | |-------------------------------------------------| 16. | 6 Train 1 0 385 20 1 | 17. | 6 Bus 0 1 452 13 0 | 18. | 6 Car 0 0 284 12 0 | +-------------------------------------------------+ . . // * Section 6.7.2: estimating the conditional logit model . . clogit choice train bus time invc, group(id) nolog Conditional (fixed-effects) logistic regression Number of obs = 456 LR chi2(4) = 172.06 Prob > chi2 = 0.0000 Log likelihood = -80.961135 Pseudo R2 = 0.5152 ------------------------------------------------------------------------------ choice | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- train | 2.671238 .453161 5.89 0.000 1.783059 3.559417 bus | 1.472335 .4007151 3.67 0.000 .6869475 2.257722 time | -.0191453 .0024509 -7.81 0.000 -.0239489 -.0143417 invc | -.0481658 .0119516 -4.03 0.000 -.0715905 -.0247411 ------------------------------------------------------------------------------ . . // * Section 6.7.3: interpreting results from -clogit- . . * odds ratios . listcoef clogit (N=456): Factor Change in Odds Odds of: 1 vs 0 -------------------------------------------------- choice | b z P>|z| e^b -------------+------------------------------------ train | 2.67124 5.895 0.000 14.4579 bus | 1.47233 3.674 0.000 4.3594 time | -0.01915 -7.812 0.000 0.9810 invc | -0.04817 -4.030 0.000 0.9530 -------------------------------------------------- . * predicted probabilities . predict prob (option pc1 assumed; conditional probability for single outcome within group) . . list train bus time invc choice prob in 1/3 +-----------------------------------------------+ | train bus time invc choice prob | |-----------------------------------------------| 1. | 1 0 406 31 0 .0642477 | 2. | 0 1 452 25 0 .0107205 | 3. | 0 0 180 10 1 .9250318 | +-----------------------------------------------+ . list train bus time invc choice prob in 16/18 +-----------------------------------------------+ | train bus time invc choice prob | |-----------------------------------------------| 16. | 1 0 385 20 1 .5493771 | 17. | 0 1 452 13 0 .0643481 | 18. | 0 0 284 12 0 .3862748 | +-----------------------------------------------+ . . // * Section 6.7.4: estimating MNLM with clogit . . * load data used for -mlogit- . use nomocc2, clear (1982 General Social Survey) . * id for each case . gen id = _n . * make one record for each outcome . expand 5 (1348 observations created) . sort id . * define indicators for outcomes and choice . gen alt = mod(_n, 5) . replace alt = 5 if alt == 0 (337 real changes made) . gen choice = (occ==alt) . gen menial = (alt==1) . gen bluecol = (alt==2) . gen craft = (alt==3) . gen whitecol = (alt==4) . list id menial bluecol craft whitecol choice in 1/10, sepby(id) +---------------------------------------------------+ | id menial bluecol craft whitecol choice | |---------------------------------------------------| 1. | 1 1 0 0 0 1 | 2. | 1 0 1 0 0 0 | 3. | 1 0 0 1 0 0 | 4. | 1 0 0 0 1 0 | 5. | 1 0 0 0 0 0 | |---------------------------------------------------| 6. | 2 1 0 0 0 1 | 7. | 2 0 1 0 0 0 | 8. | 2 0 0 1 0 0 | 9. | 2 0 0 0 1 0 | 10. | 2 0 0 0 0 0 | +---------------------------------------------------+ . . * interactions between outcomes and variables . gen whiteXm = white*menial . gen whiteXbc = white*bluecol . gen whiteXc = white*craft . gen whiteXwc = white*whitecol . gen edXm = ed*menial . gen edXbc = ed*bluecol . gen edXc = ed*craft . gen edXwc = ed*whitecol . gen experXm = exper*menial . gen experXbc = exper*bluecol . gen experXc = exper*craft . gen experXwc = exper*whitecol . list id menial bluecol craft whitecol whiteXm whiteXbc whiteXc whiteXwc /// > choice in 1/5, nodisplay +---------------------------------------------------------------------------------------------+ | id menial bluecol craft whitecol whiteXm whiteXbc whiteXc whiteXwc choice | |---------------------------------------------------------------------------------------------| 1. | 1 1 0 0 0 1 0 0 0 1 | 2. | 1 0 1 0 0 0 1 0 0 0 | 3. | 1 0 0 1 0 0 0 1 0 0 | 4. | 1 0 0 0 1 0 0 0 1 0 | 5. | 1 0 0 0 0 0 0 0 0 0 | +---------------------------------------------------------------------------------------------+ . list menial bluecol craft whitecol edXm edXbc edXc edXwc in 1/5 +-------------------------------------------------------------------+ | menial bluecol craft whitecol edXm edXbc edXc edXwc | |-------------------------------------------------------------------| 1. | 1 0 0 0 11 0 0 0 | 2. | 0 1 0 0 0 11 0 0 | 3. | 0 0 1 0 0 0 11 0 | 4. | 0 0 0 1 0 0 0 11 | 5. | 0 0 0 0 0 0 0 0 | +-------------------------------------------------------------------+ . . * to test if we did this right: . mlogit occ white ed exper if alt==1, nolog Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . . * estimating the model with clogit . clogit choice whiteXm edXm experXm menial whiteXbc edXbc experXbc /// > bluecol whiteXc edXc experXc craft whiteXwc edXwc experXwc /// > whitecol, group(id) nolog Conditional (fixed-effects) logistic regression Number of obs = 1685 LR chi2(16) = 231.16 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.2131 ------------------------------------------------------------------------------ choice | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- whiteXm | -1.774306 .7550518 -2.35 0.019 -3.254181 -.2944322 edXm | -.7788519 .1146287 -6.79 0.000 -1.00352 -.5541839 experXm | -.0356509 .018037 -1.98 0.048 -.0710027 -.0002991 menial | 11.51833 1.849346 6.23 0.000 7.89368 15.14298 whiteXbc | -.5378027 .7996015 -0.67 0.501 -2.104993 1.029387 edXbc | -.8782767 .1005441 -8.74 0.000 -1.075339 -.6812139 experXbc | -.0309296 .0144086 -2.15 0.032 -.0591699 -.0026894 bluecol | 12.25956 1.668135 7.35 0.000 8.990079 15.52905 whiteXc | -1.301963 .6474136 -2.01 0.044 -2.57087 -.0330555 edXc | -.6850365 .089299 -7.67 0.000 -.8600593 -.5100138 experXc | -.0079671 .0127054 -0.63 0.531 -.0328693 .0169351 craft | 10.42698 1.517934 6.87 0.000 7.451883 13.40207 whiteXwc | -.2029212 .8693059 -0.23 0.815 -1.906729 1.500887 edXwc | -.4256943 .0922188 -4.62 0.000 -.6064398 -.2449487 experXwc | -.001055 .0143582 -0.07 0.941 -.0291966 .0270865 whitecol | 5.279722 1.683999 3.14 0.002 1.979146 8.580299 ------------------------------------------------------------------------------ . . use nomocc2, clear (1982 General Social Survey) . mlogit occ white ed exper, nolog base(5) Multinomial logistic regression Number of obs = 337 LR chi2(12) = 166.09 Prob > chi2 = 0.0000 Log likelihood = -426.80048 Pseudo R2 = 0.1629 ------------------------------------------------------------------------------ occ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- Menial | white | -1.774306 .7550543 -2.35 0.019 -3.254186 -.2944273 ed | -.7788519 .1146293 -6.79 0.000 -1.003521 -.5541826 exper | -.0356509 .018037 -1.98 0.048 -.0710028 -.000299 _cons | 11.51833 1.849356 6.23 0.000 7.893659 15.143 -------------+---------------------------------------------------------------- BlueCol | white | -.5378027 .7996033 -0.67 0.501 -2.104996 1.029391 ed | -.8782767 .1005446 -8.74 0.000 -1.07534 -.6812128 exper | -.0309296 .0144086 -2.15 0.032 -.05917 -.0026893 _cons | 12.25956 1.668144 7.35 0.000 8.990061 15.52907 -------------+---------------------------------------------------------------- Craft | white | -1.301963 .647416 -2.01 0.044 -2.570875 -.0330509 ed | -.6850365 .0892996 -7.67 0.000 -.8600605 -.5100126 exper | -.0079671 .0127055 -0.63 0.531 -.0328693 .0169351 _cons | 10.42698 1.517943 6.87 0.000 7.451864 13.40209 -------------+---------------------------------------------------------------- WhiteCol | white | -.2029212 .8693072 -0.23 0.815 -1.906732 1.50089 ed | -.4256943 .0922192 -4.62 0.000 -.6064407 -.2449479 exper | -.001055 .0143582 -0.07 0.941 -.0291967 .0270866 _cons | 5.279722 1.684006 3.14 0.002 1.979132 8.580313 ------------------------------------------------------------------------------ (Outcome occ==Prof is the comparison group) . . // * Section 6.7.5: using clogit to estimate a mixed models . . * create interactions with individual-specific variables . use travel2, clear (Greene & Hensher 1997 data on travel mode choice) . gen hincXbus = hinc*bus . gen hincXtrn = hinc*train . gen sizeXbus = psize*bus . gen sizeXtrn = psize*train . * estimate the model . clogit choice train bus time invc hincXbus hincXtrn sizeXbus sizeXtrn, /// > group(id) nolog Conditional (fixed-effects) logistic regression Number of obs = 456 LR chi2(8) = 178.97 Prob > chi2 = 0.0000 Log likelihood = -77.504846 Pseudo R2 = 0.5359 ------------------------------------------------------------------------------ choice | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- train | 3.499641 .7579659 4.62 0.000 2.014055 4.985227 bus | 2.486465 .8803643 2.82 0.005 .7609827 4.211947 time | -.0185035 .0025035 -7.39 0.000 -.0234103 -.0135966 invc | -.0402791 .0134851 -2.99 0.003 -.0667095 -.0138488 hincXbus | -.0080174 .0200322 -0.40 0.689 -.0472798 .031245 hincXtrn | -.0342841 .0158471 -2.16 0.031 -.0653438 -.0032243 sizeXbus | -.5141037 .4007012 -1.28 0.199 -1.299464 .2712563 sizeXtrn | -.0038421 .3098074 -0.01 0.990 -.6110533 .6033692 ------------------------------------------------------------------------------ . listcoef clogit (N=456): Factor Change in Odds Odds of: 1 vs 0 -------------------------------------------------- choice | b z P>|z| e^b -------------+------------------------------------ train | 3.49964 4.617 0.000 33.1036 bus | 2.48647 2.824 0.005 12.0187 time | -0.01850 -7.391 0.000 0.9817 invc | -0.04028 -2.987 0.003 0.9605 hincXbus | -0.00802 -0.400 0.689 0.9920 hincXtrn | -0.03428 -2.163 0.031 0.9663 sizeXbus | -0.51410 -1.283 0.199 0.5980 sizeXtrn | -0.00384 -0.012 0.990 0.9962 -------------------------------------------------- . . end of do-file . do st8ch7 . version 8 . capture log close