Hi All,
I am running choice models in STATA 16 MP with the new "cmclogit" command and ran into a few issues with the weights.
The set up: I have a relatively large sample: 5,275,560 observations nested in 186,421 cases (between 14-34 alternative per observation). I run the same model once without weights, and once with weighted (using probability weights):
//set up
cmset cmset id_n major_name
//unweighted model
cmclogit choice $m1 if a==0
//weighted model
cmclogit choice $m1 if a==0 [pw=weight]
The problem: the N in my weighted model dropped to 251,524 observations nested in 17966 cases. The reason for that, I found out it, is that it ran only for the subset of cases that had only 14 alternatives, even though all cases have weights, and the weights do not vary within cases. Any idea why it does that, and how can I fix it?
Also note that this problem did not occur when I estimated the same model with the acslogit command.
Thank you!
Related Posts with weights with cmclogit
Show percent within a category on a bar graphI am trying to show the percent of a category on a bar graph, when I use the option 'percentage' it …
Closest date for financial report from event dateHello forum, I am running an event study (multiple events per company) and want to map the financial…
Matching observations across years for same idHi Forum, I am struggling with something very silly but would be very helpful if someone could help…
Combining Cox Proportional Hazards model and Difference-in-DifferencesDear All, My question concerns whether it is possible to combine a Cox proportional hazards model w…
Test for coefficients of different regressionsDear All, I'm working with Fama & MacBeth regressions. My sample is divided in quintiles and I …
Subscribe to:
Post Comments (Atom)
0 Response to weights with cmclogit
Post a Comment