Am 09.11.2012 17:05, schrieb [email protected]: >>> However, after splitting into test and train: >>> " >>> sklearn.cross_validation import train_test_split >>> X_train,X_test,y_train,y_test = train_test_split >>> (dataDescrs_array,dataActs_array,test_size=.4) >>> " >> What does np.unique(y_train) look like? > > array(['0', '1'], > dtype='<S1') > > Gael hit me to the right point - when converting my classes into integers, > it now looks like this: > > array([0, 1]) > > > And the prediction now gives only 2 classes! > > > Thus, one may assume that string values as classes - "0" and "1" - rather > than integer values as classes - 0 and 1 - does not work? > As I said, it does not work for confusion matrix afaik. The forest worked and predicted strings, which the confusion matrix couldn't handle.
------------------------------------------------------------------------------ Everyone hates slow websites. So do we. Make your web apps faster with AppDynamics Download AppDynamics Lite for free today: http://p.sf.net/sfu/appdyn_d2d_nov _______________________________________________ Scikit-learn-general mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/scikit-learn-general
