Esempio n. 1
0
 def test_Logistic(self):
     X = W((40,10))
     Y = np.greater(W((40,)), 0)
     family = S.family.Binomial()
     cmodel = models(design=X, family=S.family.Binomial())
     results = cmodel.fit(Y)
     self.assertEquals(results.df_resid, 30)
Esempio n. 2
0
 def test_Logisticdegenerate(self):
     X = W((40,10))
     X[:,0] = X[:,1] + X[:,2]
     Y = np.greater(W((40,)), 0)
     family = S.family.Binomial()
     cmodel = models(design=X, family=S.family.Binomial())
     results = cmodel.fit(Y)
     self.assertEquals(results.df_resid, 31)