Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Nested logit: interpretation of results, cross-effects, choice of model


From   Morten M�rkbak <[email protected]>
To   "'[email protected]'" <[email protected]>
Subject   st: Nested logit: interpretation of results, cross-effects, choice of model
Date   Thu, 13 Jan 2005 10:16:01 +0100

Dear Statalist


We have run a nested logit model without cross-effects like the one shown
below:

. nlogitgen product = alt(prod_valg: 1 | 2, ingen: 3)
. nlogittree alt product


. gen hinc_pv= (product == 1)*hinc

. nlogit valg (alt = opdraet pris) (product = hinc_pv), group(resp_cs)


*Results*

Nested logit estimates
Levels������������ =��������� 2���������������� Number of obs����� =�����
1764
Dependent variable =������ valg���������������� LR chi2(5)�������� =�
295.8755
Log likelihood���� = -498.04627���������������� Prob > chi2������� =���
0.0000

----------------------------------------------------------------------------
--
������������ |����� Coef.�� Std. Err.����� z��� P>|z|���� [95% Conf.
Interval]
-------------+--------------------------------------------------------------
--
alt��������� |
���� opdraet |�� -.777397�� .1337804��� -5.81�� 0.000��� -1.039602��
-.5151922
������� pris |� -.0561732�� .0052065�� -10.79�� 0.000��� -.0663778��
-.0459686
-------------+--------------------------------------------------------------
--
product����� |
���� hinc_pv |�� .6079697��� .136693���� 4.45�� 0.000���� .3400564����
.875883
-------------+--------------------------------------------------------------
--
(incl. value |
�parameters) |
product����� |
� /prod_valg |� -.0657925�� .0505956��� -1.30�� 0.193��� -.1649581���
.0333731
����� /ingen |�� 3.174162�� 523.7078���� 0.01�� 0.995��� -1023.274���
1029.622
----------------------------------------------------------------------------
--
LR test of homoskedasticity (iv = 1): chi2(2)=� 112.67��� Prob > chi2 =
0.0000
----------------------------------------------------------------------------
--


The test of homoskedasticity is strongly significant, which indicate that we
should use the nested logit model.
But when we include the cross-effects like income it shows something else:

. gen hinc2=0
. replace hinc2=1 if hinc==2
. gen hinc3=0
. replace hinc3=1 if hinc==3
. gen hinc4=0
. replace hinc4=1 if hinc==4
. gen hinc5=0
. replace hinc5=1 if hinc==5
. gen hinc6=0
. replace hinc6=1 if hinc==6

. gen hinc2_opdraet=hinc2*opdraet
. gen hinc2_camp =hinc2*camp
. gen hinc2_pris= hinc2*pris

. gen hinc3_opdraet=hinc3*opdraet
. gen hinc3_camp =hinc3*camp
. gen hinc3_pris= hinc3*pris

. gen hinc4_opdraet=hinc4*opdraet
. gen hinc4_camp =hinc4*camp
. gen hinc4_pris= hinc4*pris

. gen hinc5_opdraet=hinc5*opdraet
. gen hinc5_camp =hinc5*camp
. gen hinc5_pris= hinc5*pris

. gen hinc6_opdraet=hinc6*opdraet
. gen hinc6_camp =hinc6*camp
. gen hinc6_pris= hinc6*pris


. nlogit valg (alt = opdraet hinc2_opdraet hinc3_opdraet hinc4_opdraet
hinc5_opdraet hinc6_opdraet camp hinc2_camp ��>hinc3_camp hinc4_camp
hinc5_camp hinc6_camp pris hinc2_pris hinc3_pris hinc4_pris hinc5_pris
hinc6_pris) (product = >hinc_pv), group(resp_cs)

*Results*

Nested logit estimates
Levels������������ =��������� 2���������������� Number of obs����� =�����
1764
Dependent variable =������ valg���������������� LR chi2(20)������� =�
336.9332
Log likelihood���� = -477.51741���������������� Prob > chi2������� =���
0.0000

----------------------------------------------------------------------------
--
������������ |����� Coef.�� Std. Err.����� z��� P>|z|���� [95% Conf.
Interval]
-------------+--------------------------------------------------------------
--
alt��������� |
���� opdraet |� -.3761356�� .1358182��� -2.77�� 0.006��� -.6423344��
-.1099368
hinc2_opdr~t |� -.4859041�� .2619602��� -1.85�� 0.064��� -.9993367���
.0275285
hinc3_opdr~t |� -1.863939�� .5767165��� -3.23�� 0.001��� -2.994283��
-.7335956
hinc4_opdr~t |� -2.389885�� 1.211264��� -1.97�� 0.048��� -4.763919��
-.0158514
hinc5_opdr~t |� -1.509862�� 29.31788��� -0.05�� 0.959��� -58.97185���
55.95212
hinc6_opdr~t |� -2.039791�� 1.498528��� -1.36�� 0.173��� -4.976853���
.8972696
������� camp |�� .1921066�� .1345396���� 1.43�� 0.153��� -.0715862���
.4557994
� hinc2_camp |� -.5078718�� .2550651��� -1.99 ��0.046���� -1.00779��
-.0079535
� hinc3_camp |� -.8100644�� .6336513��� -1.28�� 0.201��� -2.051998���
.4318694
� hinc4_camp |�� .3673192�� 1.219226���� 0.30�� 0.763��� -2.022319���
2.756957
� hinc5_camp |�� 9.553992�� 122.1672���� 0.08�� 0.938��� -229.8894���
248.9973
� hinc6_camp |� -2.313999�� 1.308841��� -1.77�� 0.077���� -4.87928���
.2512827
������� pris |� -.0382855�� .0041085��� -9.32�� 0.000��� -.0463379��
-.0302331
� hinc2_pris |� -.0319209�� .0081915��� -3.90�� 0.000��� -.0479759��
-.0158659
� hinc3_pris |� -.0328219�� .0150957��� -2.17�� 0.030���� -.062409��
-.0032348
� hinc4_pris |� -.0662589�� .0180471��� -3.67�� 0.000��� -.1016305��
-.0308873
� hinc5_pris |� -.2871902�� 2.325232��� -0.12�� 0.902��� -4.844561����
4.27018
� hinc6_pris |� -.0901107�� .0513315��� -1.76�� 0.079��� -.1907187���
.0104972
-------------+--------------------------------------------------------------
--
product����� |
���� hinc_pv |�� 3.090613�� .4037683���� 7.65�� 0.000���� 2.299241���
3.881984
-------------+--------------------------------------------------------------
--
(incl. value |
�parameters) |
product����� |
� /prod_valg |�� .9057597��� .186808���� 4.85�� 0.000���� .5396227���
1.271897
����� /ingen |�� 251.3757��������� .������� .������ .�������� ���.����������
.
----------------------------------------------------------------------------
--
LR test of homoskedasticity (iv = 1): chi2(1)=��� 0.23��� Prob > chi2 =
0.6291
----------------------------------------------------------------------------
--

Know the homoskedasticity test is not significant, and we should not use a
nested logit model, but a conditional logit
instead cf. Stata manual [R] nested logit p. 70 bottompage.

It does not help to exclude the non-significant parameters in the main model
like this:

.nlogit valg (alt = opdraet hinc3_opdraet hinc4_opdraet pris hinc2_pris
hinc3_pris hinc4_pris ) (product = hinc_pv), >group(resp_cs)

*Results*

Nested logit estimates
Levels������������ =���� �����2���������������� Number of obs����� =�����
1764
Dependent variable =������ valg���������������� LR chi2(10)������� =�
313.5186
Log likelihood���� = -489.22471���������������� Prob > chi2������� =���
0.0000

----------------------------------------------------------------------------
--
������������ |����� Coef.�� Std. Err.����� z��� P>|z|���� [95% Conf.
Interval]
-------------+--------------------------------------------------------------
--
alt��������� |
���� opdraet |� -.4446482�� .1198307�� �-3.71�� 0.000��� -.6795121��
-.2097843
hinc3_opdr~t |� -2.000431�� .4646459��� -4.31�� 0.000���� -2.91112��
-1.089742
hinc4_opdr~t |� -1.754345�� .5881491��� -2.98�� 0.003��� -2.907096��
-.6015937
������� pris |� -.0324687�� .0036488��� -8.90�� 0.000� ��-.0396202��
-.0253173
� hinc2_pris |� -.0487302�� .0069067��� -7.06�� 0.000���� -.062267��
-.0351934
� hinc3_pris |� -.0409392��� .012338��� -3.32�� 0.001��� -.0651213��
-.0167571
� hinc4_pris |� -.0665196�� .0164957��� -4.03�� 0.000��� -.0988505��
-.0341886
-------------+--------------------------------------------------------------
--
product����� |
���� hinc_pv |�� 2.965018�� .3708016���� 8.00�� 0.000����� 2.23826���
3.691776
-------------+--------------------------------------------------------------
--
(incl. value |
�parameters) |
product����� |
� /prod_valg |�� .8980403�� .1772395���� 5.07�� 0.000���� .5506573���
1.245423
����� /ingen |�� 1.489712�� 185.1048���� 0.01�� 0.994��� -361.3091���
364.2885
----------------------------------------------------------------------------
--
LR test of homoskedasticity (iv = 1): chi2(2)=��� 0.31��� Prob > chi2 =
0.8582


Now the question is which model should we use to model our survey (discrete
choice survey, with to alternatives pr. choice set, and an opt-out
included)? And are we including the cross-effects the right way?


Regards

Morten M�rkbak
Danish Research Institute of Food Economics Agricultural Policy 
Research Division Rolighedsvej 25, DK-1958 Copenhagen 
Email: [email protected], homepage: www.foi.dk
phone: +4535286869, Fax:+4535286801


*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index