set memory 50m set more off log using extended_choice.log, replace *** Multinomial logit use http://www.stata-press.com/data/r8/sysdsn3 tabulate insure mlogit insure age male nonwhite site2 site3 *** Conditional logit * matched sample use http://www.stata-press.com/data/r8/clogitid list y x1 x2 id in 1/11 clogit y x1 x2, group(id) * 1:1 matching use http://www.stata-press.com/data/r8/lowbirth list low lwt smoke pairid in 1/12 clogit low lwt smoke ptd ht ui race2 race3, strata(pairid) nolog * FE logit use http://www.stata-press.com/data/r8/union clogit union age grade not_smsa south black, group(idcode) * conditional logit (McFadden's) use http://www.stata-press.com/data/r8/choice list id car choice dealer sex income in 1/12 gen japan = (car == 2) gen europe = (car == 3) gen sexjap = sex*japan gen sexeur = sex*europe gen incjap = income*japan gen inceur = income*europe clogit choice japan europe dealer sexjap sexeur incjap inceur, group(id) clogit choice sexjap incjap japan sexeur inceur europe, group(id) keep if choice == 1 mlogit car sex income *** nlogit use http://www.stata-press.com/data/r8/restaurant, clear list family_id restaurant chosen kids rating distance in 1/14, sepby(fam) abbrev(10) nlogitgen type = restaurant(1 2, 3 4 5, 6 7) nlogittree restaurant type gen incfast = (type == 1) * income gen incfancy = (type == 3) * income gen kidfast = (type == 1) * kids gen kidfancy = (type == 3) * kids clogit chosen cost rating distance incfast kidfast incfancy kidfancy, group(family_id) estimates store fullset clogit chosen cost rating distance incfast kidfast if type != 2, group(family_id) hausman . fullset nlogit chosen (restaurant = cost rating distance) (type = incfast incfancy kidfast kidfancy), group(family_id) nolog *** Ordered logit / probit use http://www.stata-press.com/data/r8/fullauto, clear ologit rep77 foreign length mpg, table oprobit rep77 foreign length mpg, table *** Biprobit use http://www.stata-press.com/data/r8/school biprobit private vote years logptax loginc biprobit (private = years logptax loginc) (vote = years logptax loginc)