Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error while loading credit data #43

Open
shubhamgupta-dat opened this issue Aug 19, 2020 · 2 comments
Open

Error while loading credit data #43

shubhamgupta-dat opened this issue Aug 19, 2020 · 2 comments

Comments

@shubhamgupta-dat
Copy link

I was trying to read credit data from the example page. Pandas cannot read from excel sheet because of the incorrect variable name sheetname and should be renamed to sheet_name.

Adding the log trace for Error:

---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-6-d1105f71ff0d> in <module>
      1 # Importing data
----> 2 dataset = load_credit_data()
      3 X = dataset.data
      4 y = dataset.target
      5 # Shuffling data, preparing target and variables

/opt/conda/lib/python3.7/site-packages/skrules/datasets/credit_data.py in load_credit_data()
     37 
     38     data = pd.read_excel(join(sk_data_dir, archive.filename),
---> 39                          sheetname='Data', header=1)
     40 
     41     dataset = Bunch(

/opt/conda/lib/python3.7/site-packages/pandas/util/_decorators.py in wrapper(*args, **kwargs)
    294                 )
    295                 warnings.warn(msg, FutureWarning, stacklevel=stacklevel)
--> 296             return func(*args, **kwargs)
    297 
    298         return wrapper

TypeError: read_excel() got an unexpected keyword argument 'sheetname'
@shubhamgupta-dat
Copy link
Author

I will make the changes and create a pull request for the same.

@ngoix
Copy link
Member

ngoix commented Aug 30, 2020

I will make the changes and create a pull request for the same.

thanks for reporting, yes please don't hesitate to open a pull request changing deprecated sheetname to sheet_name

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants