[Limdep Nlogit List] question about defining universal choice set when all choices aren't available to everyone

Kristy Wallmo - NOAA Federal kristy.wallmo at noaa.gov
Sat Apr 8 09:02:16 AEST 2023


Dear Dr. Greene,

I am trying to estimate a location choice model for fishermen and am
following the example you provide in the Nlogit documentation where not
everyone has every alternative available to them.  In my case everyone’s
choice set contains 15 alternatives, and the universal set of alternatives
is 71 sites.  I am starting with a very simple model where site choice is
function of expected revenue( bigeye_o), trip cost (tripcost) and other
boats (boats5x5)























My code is the following:



NLOGIT ; Lhs = chosen,  nij,  altij

    ; Choices =
1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71

    ; Rhs = bigeye_o, boats5x5, tripcost

    ; check data $



nij is 15 for everyone, and altij is a suite of 15 different site numbers.
I have defined the universal choice set as both numbers 1- 71 and tried
using generic labels e.g. a, b, c,..etc.  When I use the check data I get
the errors below, and my first question is about the missing values:  I
have checked and double checked and I do not have any missing data in the
dataset, and all data is numeric.  Second, within each set of the 15 choice
alternatives there are no duplicates, so I am not quite understanding the
bulk of the error messages.  Any advice you have would be much appreciated.
 – thanks Kristy

+----------------------------------------------------------+

| Inspecting the data set before estimation.               |

| These errors mark observations which will be skipped.    |

| Row Individual = 1st row then group number of data block |

+----------------------------------------------------------+

    0   2270  Missing value found for characteristic or attribute in utility

    0   2540  Universal choice set, ID var. (3rd LHS) takes same value twice

    0   2541  Universal choice set, ID var. (3rd LHS) takes same value twice

    0   2542  Universal choice set, ID var. (3rd LHS) takes same value twice

    0   2543  Universal choice set, ID var. (3rd LHS) takes same value twice

    0   2544  Universal choice set, ID var. (3rd LHS) takes same value twice

    0   2545  Universal choice set, ID var. (3rd LHS) takes same value twice

38179   2546  Universal choice set, ID var. (3rd LHS) takes same value twice

    0   2547  Universal choice set, ID var. (3rd LHS) takes same value twice

  I shortened this but basically 196 error lines that say this…

    0   8690  Missing value found for characteristic or attribute in utility



Normal exit:   5 iterations. Status=0, F=    17957.48



-----------------------------------------------------------------------------

Discrete choice (multinomial logit) model

Dependent variable               Choice

Log likelihood function    -17957.48310

Estimation based on N =   8768, K =   3

Inf.Cr.AIC  =  35921.0 AIC/N =    4.097

Model estimated: Apr 07, 2023, 12:25:22

R2=1-LogL/LogL* Log-L fncn R-sqrd R2Adj

Constants only must be computed directly

               Use NLOGIT ;...;RHS=ONE$

Response data are given as ind. choices

Number of obs.=  8964, skipped  196 obs

--------+--------------------------------------------------------------------

        |                  Standard            Prob.      95% Confidence

  CHOSEN|  Coefficient       Error       z    |z|>Z*         Interval

--------+--------------------------------------------------------------------

BIGEYE_O| .79760D-05***   .6999D-06    11.40  .0000  .66042D-05  .93478D-05

BOATS5X5|     .06895***      .00108    63.89  .0000      .06683    .07106

TRIPCOST|    -.00031***   .8394D-05   -37.20  .0000     -.00033   -.00030

--------+--------------------------------------------------------------------

Note: nnnnn.D-xx or D+xx => multiply by 10 to -xx or +xx.

Note: ***, **, * ==>  Significance at 1%, 5%, 10% level.

-----------------------------------------------------------------------------

-- 
Kristy Wallmo, Ph.D.
Economist, National Marine Fisheries Service
Silver Spring, MD


More information about the Limdep mailing list