How to change python version in anaconda spyder

I am using Python version 3.6 in anaconda spyder on my mac. But I want to change it to Python 2.7.

Can someone tell me how to do this?

+7
python anaconda spyder data-science
source share
4 answers

You can open the settings (several options):

  • keyboard shortcut Ctrl + Alt + Shift + P
  • ToolsPreferences

And depending on the version of Spyder, you can change the interpreter in the Python interpreter section (Spyder 3.x):

enter image description here

or in the extended Console section (Spyder 2.x):

enter image description here

+9
source share

In the settings, select Python Interpreter

In Python Interpreter, change the Default value to Use the following Python interpreter

The path there should be the default Python executable. Find your Python 2.7 executable and use it.

+2
source share

If you want to keep python 3, you can follow these instructions to create a python 2.7 environment called py27.

Then you just need to activate py27:

 $ conda activate py27 

Then you can install spyder in this environment, for example:

 $ conda install spyder 

Then you can run spyder from the command line or go to version 2.7 spyder.exe under the envs directory (for example, C: \ ProgramData \ Anaconda3 \ envs \ py27 \ Scripts)

+2
source share

Just download the Python2.7 Anaconda installer from your website .

0
source share

All Articles