WillKoehrsen / feature-selector

Feature selector is a tool for dimensionality reduction of machine learning datasets
GNU General Public License v3.0
2.23k stars 768 forks source link

Zero-size array to reduction operation minimum which has no identity #14

Open Adelija opened 5 years ago

Adelija commented 5 years ago

Hello Will, Thanks for sharing your code.

I tried my dataset using this code

from feature_selector import FeatureSelector
import pandas as pd
train = pd.read_csv('data/data_linkpower-Adela4.csv')
train_labels = train['type_new']
print (train.head())
fs = FeatureSelector(data = train, labels = train_labels)

fs.identify_collinear(correlation_threshold = 0.98)
fs.plot_collinear()

and got error:


  File "C:\Users\Adela\Anaconda3\lib\site-packages\numpy\core\_methods.py", line 32, in _amin
    return umr_minimum(a, axis, None, out, keepdims, initial)

ValueError: zero-size array to reduction operation minimum which has no identity

Can you please tell me what is a possible solution.

All the best, Adela

free-free commented 5 years ago

More information about your code and error is more helpful to diagnose your problem