Python Forum

Full Version: unable to locate package - pandas datareader
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi I'm new to the world of programming and I am really under pressure to learn python at the moment for a mature student college course. So im looking for help on how to get python pandas installed on ubuntu 16.04, specifically pandas datareader. I might need more help later too, to get my head around this. I have no programming experience and very little linux experience.

I'm doing the basic introduction on python and stuck on the second part.

import pandas_datareader.data as web

https://pythonprogramming.net/data-analy...roduction/

I've visited https://github.com/pydata/pandas-datareader but do not know what to do after this part, do I need to download something else.

Quote:import pandas.io.data as web
/usr/lib/python3/dist-packages/pandas/io/data.py:33: FutureWarning:
The pandas.io.data module is moved to a separate package (pandas-datareader) and will be removed from pandas in a future version.
After installing the pandas-datareader package (https://github.com/pydata/pandas-datareader), you can change the import from pandas.io import data, wb to from pandas_datareader import data, wb.
FutureWarning)
(Apr-11-2018, 08:39 PM)Grin Wrote: [ -> ]and very little linux experience
Python works fine on Windows. If it's easier to learn one thing at a time, you don't have to be on linux.

For the datareader, you can install it with pip install pandas-datareader.
It's just a change of import in newer version.
So after Pandas 0.19.0,it's from pandas_datareader import data, wb
Test.
G:\Anaconda3
λ python -m ptpython
>>> import pandas as pd

>>> pd.__version__
'0.22.0'

# So i have newest version,then this is correct
>>> from pandas_datareader import data, wb


# Old import not do use,if not get message upgrade Pandas
>>> from pandas.io import data, wb
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "G:\Anaconda3\lib\site-packages\pandas\io\data.py", line 2, in <module>
    "The pandas.io.data module is moved to a separate package "
........
you can change the import ``from pandas.io import data, wb`` to ``from pandas_datareader import data, wb``.
Thanks for the replies, im stuck on Linux for no reason other than the cost to upgrade my machine (broke dad to 3 lovely kids), so to get a bit more mph I installed Ubuntu on my old windows desktop. It works great but it is another thing to get my head around I guess.. So I successfully installed pycharm and will hopefully be using that later down the road, I'm almost there with pandas with the help from you guys.

Apart from the link I supplied is there any specific data mining tutorials I should be looking at or books to read (download). I'm looking to get scatter plots and charts out of sample datasets, ie insurance datasets so that's my main concern now.