I have problems while running nested logit mode.
gen grp = group(210)
sort grp
by grp: gen travel=_n-1
list in 1/10
label define tlab 0 "air" 1 "train" 2 "bus" 3 "car"
label value travel tlab
tab travel
nlogitgen type = travel(fly: 0, ground: 1 | 2 | 3)
gen aasc = mod(_n, 4)==1
gen tasc = mod(_n, 4)==2
gen basc = mod(_n, 4)==3
gen casc = mod(_n, 4)==0
gen hincair = hinc*aasc
Then finally,
nlogit mode (travel = aasc tasc basc gc ttme hincair), group(grp)
when i turn nlogit command the last on stata tell me :
. nlogit mode (travel = aasc tasc basc gc ttme)
> (type=hincair), group(grp)
option case() required
i tried a lot of examples i have always same problem thanks for your answers