Home > Enterprise >  ModuleNotFoundError: No module named 'Pandas' while having Pandas in the correct path?
ModuleNotFoundError: No module named 'Pandas' while having Pandas in the correct path?

Time:12-10

I'm a begginer with some experience in R, I just started with Python and following instructions I installed Anaconda. But I can't find a way to import Pandas.

If I type: "import Pandas as pd" it shows:

Traceback (most recent call last): File "<stdin>", line 1, in <module> ModuleNotFoundError: No module named 'Pandas' And I receive the same on iPython and in the Jupyter Notebook. I've tried to manually install by:

"conda install Pandas" but it says that

All requested packages already installed. I've also tried:

import sys

sys.path

And it returns: ['', 'C:\ProgramData\Anaconda3\python39.zip', 'C:\ProgramData\Anaconda3\DLLs', 'C:\ProgramData\Anaconda3\lib', 'C:\ProgramData\Anaconda3', 'C:\Users\myname\AppData\Roaming\Python\Python39\site-packages', 'C:\ProgramData\Anaconda3\lib\site-packages', 'C:\ProgramData\Anaconda3\lib\site-packages\win32', 'C:\ProgramData\Anaconda3\lib\site-packages\win32\lib', 'C:\ProgramData\Anaconda3\lib\site-packages\Pythonwin'] while the Pandas package is at: C:\ProgramData\Anaconda3\pkgs\pandas-1.5.2-py39hf11a4ad_0

so I don't think it's a path problem (?). I only have 1 environment in Anaconda, the base (root) by default. I've search a lot and can't find the solution, so thanks in advance.

CodePudding user response:

You type pandas wrong.

It's not Pandas it's pandas.

Try this.

import pandas as pd
  • Related