I see, as far as I know, your X input array should be a n_samples x n_features array. Is this true in your case?
Btw. instead of converting the inputs to Python lists , you could also get the counts via a1 = x[x == 1.0].shape[0] b1 = y[y == 1.0].shape[0] And maybe a few extra lines assert set(np.unique(x)).issubset({0.0, 1.0}) assert set(np.unique(x)).issubset({0.0, 1.0}) would be useful for debugging purposes?! > On Jan 12, 2016, at 2:01 PM, Herbert Schulz <hrbrt....@gmail.com> wrote: > > Yes, it is a number between 0 and 1. > > but im calculating it, depended on 2 samples. So x and y. And if im counting > the 1's in x and the 1's in y, i should get the coef with return float(c)/(a1 > + b1 - c) > > But i cannot count 1's in x if x is a skalar. > > > > ------------------------------------------------------------------------------ > Site24x7 APM Insight: Get Deep Visibility into Application Performance > APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month > Monitor end-to-end web transactions and take corrective actions now > Troubleshoot faster and improve end-user experience. Signup Now! > http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140_______________________________________________ > Scikit-learn-general mailing list > Scikit-learn-general@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/scikit-learn-general ------------------------------------------------------------------------------ Site24x7 APM Insight: Get Deep Visibility into Application Performance APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month Monitor end-to-end web transactions and take corrective actions now Troubleshoot faster and improve end-user experience. Signup Now! http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140 _______________________________________________ Scikit-learn-general mailing list Scikit-learn-general@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/scikit-learn-general