I have sent this problem to Stata tech support. I will be amazed if anyone on the list can help me but I figured I would toss it out just in case anyone has encountered a similar problem.
My gologit2 program, first introduced in 2006, works fine in Stata 11.2 through Stata 14. For example, in Stata 14, if I give the commands
I get
I also went way back to Stata 11.2 and it worked fine there too (once I dropped nofvlabel). But, if I give the exact same commands in Stata 15, I get
That is, I get these incredibly small but highly significant junk parameter estimates for 0.male and 0.white. Those junk parameters don't seem to affect anything thing else, e.g. the DF and chi-square are the same, as are the other parameter estimates. They are really annoying but the estimates are basically 0 so they don't have much impact.
gologit2 calls the ml command. My guess is that something changed in ml in Stata 15 that causes it to add these junk parameters. That may need fixes on Stata's end, but I am happy to program around it on my side if I can figure out how.
Also, you can bypass gologit2 and call ml directly, and the problem is the same. I've tried tweaking the ml command (e.g. drop the collinear option) but so far no luck. Dropping the 0b. variables doesn't work if there are more than 2 categories to a variable. If there is some option I can add to ml that will make the problem go away I would love to know what it is! Thanks
My gologit2 program, first introduced in 2006, works fine in Stata 11.2 through Stata 14. For example, in Stata 14, if I give the commands
Code:
use https://www3.nd.edu/~rwilliam/statafiles/ordwarm2, clear gologit2 warm i.male i.white, auto waldforce nolabel nofvlabel
Code:
Generalized Ordered Logit Estimates Number of obs = 2,293 Wald chi2(4) = 97.78 Prob > chi2 = 0.0000 Log likelihood = -2944.6035 Pseudo R2 = 0.0171 ( 1) [eq1]1.white - [eq2]1.white = 0 ( 2) [eq2]1.white - [eq3]1.white = 0 ------------------------------------------------------------------------------ warm | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- eq1 | 1.male | -.3042833 .1247377 -2.44 0.015 -.5487647 -.0598019 1.white | -.3331343 .1159147 -2.87 0.004 -.5603229 -.1059457 _cons | 2.351311 .1366675 17.20 0.000 2.083447 2.619174 -------------+---------------------------------------------------------------- eq2 | 1.male | -.5922755 .0851572 -6.96 0.000 -.7591805 -.4253705 1.white | -.3331343 .1159147 -2.87 0.004 -.5603229 -.1059457 _cons | .7943304 .117114 6.78 0.000 .5647912 1.02387 -------------+---------------------------------------------------------------- eq3 | 1.male | -1.01099 .1195953 -8.45 0.000 -1.245393 -.7765879 1.white | -.3331343 .1159147 -2.87 0.004 -.5603229 -.1059457 _cons | -.8269653 .1184391 -6.98 0.000 -1.059102 -.5948289 ------------------------------------------------------------------------------
Code:
Generalized Ordered Logit Estimates Number of obs = 2,293 Wald chi2(4) = 97.78 Prob > chi2 = 0.0000 Log likelihood = -2944.6035 Pseudo R2 = 0.0171 ( 1) [eq1]1.white - [eq2]1.white = 0 ( 2) [eq2]1.white - [eq3]1.white = 0 ------------------------------------------------------------------------------ warm | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- eq1 | 1.male | -.3042833 .1247377 -2.44 0.015 -.5487647 -.0598019 1.white | -.3331343 .1159147 -2.87 0.004 -.5603229 -.1059457 _cons | 2.351311 .1366675 17.20 0.000 2.083447 2.619174 -------------+---------------------------------------------------------------- eq2 | 0.male | -3.38e-16 3.76e-17 -8.99 0.000 -4.12e-16 -2.64e-16 1.male | -.5922755 .0851572 -6.96 0.000 -.7591805 -.4253705 0.white | 9.66e-17 1.72e-17 5.62 0.000 6.29e-17 1.30e-16 1.white | -.3331343 .1159147 -2.87 0.004 -.5603229 -.1059457 _cons | .7943304 .117114 6.78 0.000 .5647912 1.02387 -------------+---------------------------------------------------------------- eq3 | 1.male | -1.01099 .1195953 -8.45 0.000 -1.245393 -.7765879 1.white | -.3331343 .1159147 -2.87 0.004 -.5603229 -.1059457 _cons | -.8269653 .1184391 -6.98 0.000 -1.059102 -.5948289 ------------------------------------------------------------------------------
gologit2 calls the ml command. My guess is that something changed in ml in Stata 15 that causes it to add these junk parameters. That may need fixes on Stata's end, but I am happy to program around it on my side if I can figure out how.
Also, you can bypass gologit2 and call ml directly, and the problem is the same. I've tried tweaking the ml command (e.g. drop the collinear option) but so far no luck. Dropping the 0b. variables doesn't work if there are more than 2 categories to a variable. If there is some option I can add to ml that will make the problem go away I would love to know what it is! Thanks
Code:
use https://www3.nd.edu/~rwilliam/statafiles/ordwarm2, clear constraint 1998 [eq1]1.white = [eq2]1.white constraint 1999 [eq1]1.white = [eq3]1.white ml model lf gologit2_ll /// (eq1:warm= 0b.male 1.male 0b.white 1.white) (eq2: 0b.male 1.male 0b.white 1.white) /// (eq3: 0b.male 1.male 0b.white 1.white) , /// constraints(1999 1998) waldtest(-3) /// lf0(3 -2995.770427280555) collinear /// title(Generalized Ordered Logit Estimates) missing maximize nocnsnotes nolog collinear ml display, nofvlabel
Comment