Code:
mlogit depvar ibn.fvar1 othervars
if i
Code:
tab depvar fvar1
Alt1 | Alt2 | Alt3 | Alt4 | |
Group1 | 100 | 80 | 0 | 0 |
Group2 | 0 | 50 | 40 | 0 |
Group3 | 0 | 0 | 60 | 40 |
Code:
constraint define 1 [Alt1]2.group = -99999 constraint define 2 [Alt1]3.group = -99999 constraint define 3 [Alt2]3.group = -99999 constraint define 4 [Alt3]1.group = -99999 constraint define 5 [Alt4]1.group = -99999 constraint define 6 [Alt4]2.group = -99999
Code:
mlogit depvar ibn.fvar othervariables, constraint(1/6)
so it adds the constraint
Code:
constraint define 1997 [Alt2]1o.group = 0 constraint define 1998 [Alt2]2o.group = 0 constraint define 1999 [Alt2]3o.group = 0
and estimates the model internally with constraints 1 2 4/6 1997/1999
I got estimates for the coefficients.
Stata returns for example coefficients like 20 and 19 for group3 in the equations for Alt3 and Alt4 (and uses 0 for Alt2 internally), so that the prediction results in reasonable values (10E-6 probability for Alt2 and 0.6 and 0.4 for Alt3 and Alt4). but the standard errors and z-values for the coefficients are not useful.
I could define another baseoutcome with
Code:
mlogit ibn.fvar othervariables, constraint(1/6) baseoutcome(1)
Is it somehoe possible not to define a baseoutcome at all for mlogit (or other similar commands) and to define all constraints for the baseoutcome manually?
So in this case:
keep the -99999 as a constraint for [Alt2]1.group
and define manually a different baseoutcome for group 3 (taking Alt3 instead of Alt2)
So using the following constraints:
Code:
constraint define 1 [Alt1]2.group = -99999 constraint define 2 [Alt1]3.group = -99999 constraint define 3 [Alt2]3.group = -99999 constraint define 4 [Alt3]1.group = -99999 constraint define 5 [Alt4]1.group = -99999 constraint define 6 [Alt4]2.group = -99999 constraint define 1997 [Alt2]1o.group = 0 constraint define 1998 [Alt2]2o.group = 0 constraint define 1999 [Alt3]3o.group = 0
I hope you all stay healthy these days,
Max
0 Response to define constraints for baseoutcome in mlogit
Post a Comment