user10109563
user10109563

Reputation: 31

pandas work on jupyter but not recognized in cmd or anaconda prompt

I want to run a script in .py with cmd or anaconda prompt but says pandas can't be recognized.

'pandas' in sys.modules
 False

the version of python is the correct where these libraries are installed. The correct path is somehow not in connection with the cmd and all the libraries installed with the anaconda are not seen. How to make it work without installing all the modules again?

Upvotes: 1

Views: 1542

Answers (2)

user10109563
user10109563

Reputation: 31

The solution was to write the word python too.

python hx.py

now it runs if typed in the anaconda prompt.

All nice.

Upvotes: 1

Inder
Inder

Reputation: 3816

Usually this is fixed with a simple from command line:

python -m pip install pandas

if this doesn't help, I will suggest you to remove all the python packages and do an anaconda reinstall on your system

Upvotes: 0

Related Questions