Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Jupyter Notebook - ModuleNotFoundError [duplicate]

I have Python 3.7 installed on my windows 10 laptop. i installed pandas and numpy a few days ago on my laptop and they worked fine when used in my jupyter notebook by writing import numpy as np and import pandas as pd. But today when i started my jupyter notebook again to practice the same error occurred a quite a few times. ModuleNotFoundError: No module named 'numpy'

I tried restarting the jupyter kernel many times and then executed the statement again and again but the same error displayed each time.

I've installed numpy using pip install numpy and pandas using pip install pandas

i already tried installing pandas and numpy through my jupyter notebook using !pip install numpy and !pip install pandas but the problem remains the same. Check out the below screenshots. Click on the link to view.

pandas error

numpy error

I'm still learning python so can you please help me with this. I don't know what to do.

like image 831
the_coder Avatar asked Oct 18 '18 15:10

the_coder


People also ask

How do you solve ModuleNotFoundError in Jupyter Notebook?

If you're getting ModuleNotFoundError in Jupyter, first double-check that you installed the package with pip install . Triple-check you didn't misspell the package name in your import, otherwise you'll waste a lot of time reading this page.

Can I duplicate a Jupyter Notebook?

New Notebook: Start a new notebook (another browser panel like this one) Open...: Select a file to open from the notebook Files view. Make a Copy...: Copy the current notebook completely into another browser panel.

How do you duplicate a cell in Jupyter Notebook?

X will cut the selected cell. C will copy the selected cell. V will paste the cell which is being copied/cut. Shift + V paste cells above.


1 Answers

Open a notebook. Install your packages through the notebook by entering in a notebook cell -

!pip install numpy
!pip install pandas

Then import

like image 192
pyeR_biz Avatar answered Oct 20 '22 01:10

pyeR_biz