Python Pandas - Missing required dependencies ['numpy'] 1

前端 未结 28 2446
清歌不尽
清歌不尽 2020-11-27 16:32

Since yesterday I\'ve had this error when I try to import packages on anaconda :

ImportError: Missing required dependencies [\'numpy\']

I have t

28条回答
  •  醉梦人生
    2020-11-27 17:05

    In my case even though I was using the above options of uninstall and installing using pip the code was still giving me same errors.

    Finally, I created a vritual environment and Installed numpy and pandas using pip in my virtual env. Now the code is running.

    Steps: for Anaconda3 - Please change according to your installation type: [if you dont have virtual env package installed]

    $ pip install virtualenv
    

    [from command prompt go to the directory by c:\anadonda3\scripts

    [write the following command to use virtual env to create a virtual env for you in your desired location]

    $virtualenv c:\anaconda3\envs\my_virtual_env
    

    [once created you will have to activate your virtual env]

    $c:\anaconda3\envs\my_virtual_env\scripts activate
    

    [now pip install numpy and pandas and other required packages using pip]

    [once installations are done exit from the virtual env]

    $c:\anaconda3\envs\my_virtual_env\scripts deactivate
    

    now use the python.exe inside your virtual env folder to run the script and it will run even with python 3.7.

提交回复
热议问题