1

Initially, I installed Python and also Anaconda. When I imported basic packages like pandas using python on command prompt, it was not reflecting in Spyder. Then I realized that my python installation is different from the Spyder installation. After that, I uninstalled python and using only Spyder. Is this the correct way? If not, how to install packages in python and get them reflected in spyder?

Sorry if I'm missing some fundamentals here.

U12
  • 83
  • 3
  • 11

1 Answers1

0

What I think is happening is that you installed Spyder in your local pip and pandas in your conda environment.
( more details on this here : conda vs pip )

What I suggest to do is:
1 - create a new environment:
conda create --name my_env python==3.7.
2 - activate the environment:
conda activate my_env
3 - inside the activated environment install Spyder and the packages:
conda install spyder
conda install pandas
4 - still inside the activated environment, launch Spyder:
spyder

Additional note:
Spyder is a package.
If you install it both in pip and in conda you will have it twice.

Hence, if you run spyder without the environment you will be able to use the packages installed in pip (use pip freeze to check them).

If you run spyder within a environment you will be able to use the packages of that environment (use conda list to check them)

pguardati
  • 229
  • 2
  • 3