[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: AW: Bug in logit?

From   "Martin Weiss" <[email protected]>
To   <[email protected]>
Subject   st: AW: Bug in logit?
Date   Mon, 21 Sep 2009 13:12:58 +0200


Have you made sure there are no repetitions in the -varlist- for -logistic-?
Note that in the example below, "x1" does exhibit the behavior you
complained about:

vers 10.1

set obs 10000

gen x1=26+int(27*runiform())
gen x2=runiform()<.48

gen byte draw = /* 
 */ runiform() < /* 
 */ invlogit(1+.02*x1+.3*x2)

xi: logistic draw x1 i.x2 x1, nolog


-----Ursprüngliche Nachricht-----
Von: [email protected]
[mailto:[email protected]] Im Auftrag von Stephan
Gesendet: Montag, 21. September 2009 12:52
An: [email protected]
Betreff: st: Bug in logit?

I am fitting 120 variables to a binary outcome using logit.  Inevitably,
some of the covariates are collinear.  So, logit drops some of them.
However, one of the dropped variables nevertheless appears in the model with
a non-zero coefficient.  This is surely a bug?

Comments would be appreciated. I can send the stata output if required.

*   For searches and help try:

*   For searches and help try:

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