feature-selection

TypeError: only integer arrays with one element can be converted to an index

TypeError: only integer arrays with one element can be converted to an index Question: I’m getting the following error when performing recursive feature selection with cross-validation: Traceback (most recent call last): File “/Users/…/srl/main.py”, line 32, in <module> argident_sys.train_classifier() File “/Users/…/srl/identification.py”, line 194, in train_classifier feat_selector.fit(train_argcands_feats,train_argcands_target) File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/sklearn/feature_selection/rfe.py”, line 298, in fit ranking_ = rfe.fit(X[train], y[train]).ranking_ …

Total answers: 2