0

I am new to python. I have various versions of python installed in my Mac.

The pandas is installed in python 3.5. I want to use python 2.7. However when I do

import pandas

It says:

ImportError: No module named pandas

I tried pip install pandas but it is installing in python3.5

Can anyone suggest me how I can install modules for specific python

Tanya

  • 1
    https://stackoverflow.com/questions/10919569/install-a-module-using-pip-for-specific-python-version – Alex Dubrovsky Feb 20 '18 at 15:50
  • If you need to use multiple versions of Python, I recommend installing Anaconda or Miniconda: https://www.anaconda.com/ – Evan Feb 20 '18 at 16:04

1 Answers1

1

I would suggest you to create a virtual environment and get started with the Python version you want to work on. Link to Documentation

You may also follow easy instructions for getting your choice of Python version on IPython Notebook as well. You may follow Step 1-4 in this documentation for virtual env and Python 2.7

Hari_pb
  • 7,088
  • 3
  • 45
  • 53