Manual: Regression with Discrete Dependent Variable
Regression with Discrete Dependent Variable
Regression models for limited and qualitative dependent variables. The module currently allows the estimation of models with binary (Logit, Probit), nominal (MNLogit), or count (Poisson) data.
See Module Reference for commands and arguments.
Examples
# Load the data from Spector and Mazzeo (1980) In [1]: spector_data = sm.datasets.spector.load() In [2]: spector_data.exog = sm.add_constant(spector_data.exog) # Logit Model In [3]: logit_mod = sm.Logit(spector_data.endog, spector_data.exog) In [4]: logit_res = logit_mod.fit() Optimization terminated successfully. Current function value: 0.402801 Iterations 7 In [5]: print(logit_res.summary())
© 2009–2012 Statsmodels Developers
© 2006–2008 Scipy Developers
© 2006 Jonathan E. Taylor
Licensed under the 3-clause BSD License.
http://www.statsmodels.org/stable/discretemod.html