Reputation: 11
(py1) C:\Users\XXXXX>pip list
Version
----------------- ----------
certifi 2018.11.29
chardet 3.0.4
idna 2.8
lxml 4.3.0
numpy 1.16.0
pandas 0.23.4
pandas-datareader 0.7.0
pip 18.1
python-dateutil 2.7.5
pytz 2018.9
requests 2.21.0
scipy 1.2.0
setuptools 40.6.3
six 1.12.0
urllib3 1.24.1
wheel 0.32.3
wrapt 1.11.1
and it also works when I type python on my cmd:
` (py1) C:\Users\XXXXX>python Python 3.7.2 (tags/v3.7.2:9a3ffc0492, Dec 23 2018, 22:20:52) [MSC v.1916 32 bit (Intel)] on win32 Type "help", "copyright", "credits" or "license" for more information.
import pandas_datareader `
However, when I try importing it in Jupyter Notebook (launching from the same venv) it gives me the error below:
(py1) C:\Users\XXXXX>python
` Python 3.7.2 (tags/v3.7.2:9a3ffc0492, Dec 23 2018, 22:20:52) [MSC v.1916 32 bit (Intel)] on win32 Type "help", "copyright", "credits" or "license" for more information.
import pandas_datareader `
Upvotes: 0
Views: 667
Reputation: 11
I could resolve this, I went to my venv and executed this command: python -m pip install ipykernel and then upgraded pip and it started working.
Thank you, Mohit
Upvotes: 1
Reputation: 175
Good Morning!
so what you could try in the jupyter interface is using a magic command, so just create a new cell with the following content:
%%bash
pip install pandas-datareader
or
%%bash
pip3 install pandas-datareader
and run it afterwards. This could be maybe one solution :) did you check the connection of your python3 kernel to the correct environment?
Upvotes: 0