How do I download and install matplotlib for Python 3.5 for my mac to use in Eclipse? My mac is running macOS High Sierra version 10.13.1. I can handle quantum mechanics and thermodynamics, but the whole downloading and installing and using new python programs/packages/libraries/stuff is so hopelessly confusing to me. Assume I don't know anything, because I don't.
For scientific work using Python I recommend using Anaconda. It has all relevant packages installed.
Follow these steps:
Download Anaconda
Double Click the File in your Download Folder
For further setup with Eclipse, follow these steps.
Given that you have Python3 already installed you could also try:
python3 -m pip install matplotlib
In my experience, it is wise to consider installing a package manager like Anaconda. For something like matplotlib however, using
pip install matplotlib should be more than sufficient. For your information, the Mac already has pip (a package management system) installed, so running the above command should be enough.
Related
ERROR: Shapely-1.6.4.post2-cp36-cp36m-win_amd64.whl is not a supported wheel on this platform.
I cannot install Shapely with:
pip install "C:/path.../Shapely-1.6.4.post2-cp36-cp36m-win_amd64.whl
This is what I have tried so far:
* pip install --upgrade pip
* Python version 3.6.4, Windows 64 bit
Should I be installing another version? cp36 and win_amd64 looks correct. Unless amd means the CPU? In that case I have Intel i5. I don't see that version so I don't think that's it...
Any other suggestions on what I am doing wrong?
EDIT: Downloaded wheel from here: https://www.lfd.uci.edu/~gohlke/pythonlibs/#shapely
There's a helpful complete guide here to do so. Windows have many problems with python wheel files. If you want my advice, you better don't use Windows for python programming, Linux is perfect for such a thing. You can use Ubuntu which is great and stable.
If you really want to program python in Windows, I suggest you to install and use Anaconda. It's a great tool and helps you with installing python packages and programming in python.
EDIT: I tried the Anaconda way and it works fine. After installing Anaconda I opened Anaconda Powershell Prompt as admin (cause there was permission problem for me in installing Shapely!) and then ran the command conda install shapely. Once installation completed, I ran the command jupyter notebook and in jupyter I was able to use Shapely.
I installed the Shapely in the base environment of conda which is not good. If you want use Anaconda, you better learn how to manage environments in conda.
please help installing SciPy. I think i've tried almost any advice i could find, but still no luck.
I am using Mac High OS Sierra 10.13.1, python 3.7, trying to make this work for IntellIJ IDEA 2017.2 IDE. I have Xcode version 9.2 if that helps.
I've tried instaling from IDE, using package installer -> fails with error status code 1.
I've tried installing using pip3 install scipy
I've installed brew install gcc ( I have version 7.2.0 installed)
I've installed numpy.
I've tried to install using Macports as suggested on official site - didn't help.
I've tried to instal using brew install scipy.
I've tried to install using Conda. It installed somewhere to Conda Dir, but i still cannot access library from python file using import scipy, error: No module named scipy.
Looks like i am just going in loops now, can some one suggest any idea please?
Topics i researched:
SciPy build/install Mac Osx
Can't install Scipy through pip
"failed with error code 1" while installing scipy
Some other ones i lost links to.
Ok looks like i made it work.
This thread: helped me.
It appeared I was actaully able to install scipy package using conda. But my Python didn't see the package. So i had to:
Change Right Click on my project in IDE > Project > New > Python SDK > Add Local
Select Python in Conda dir. In my case it was /Users/[my user ]/miniconda3/bin/python3.6
Restart IDE just in case and my python script was able to see import scipy.
The downside of this - that I cannot install packages the clean way from IDE anymore for some reason. I.e. Tools > Manage Python Packages > + > doesn't find any. And I have to reinstall all the packages i had using conda install [package name] from terminal . But I am fine with it, as long as it works.
Hopefully my quest might be useful for someone.
I'm a little lost on how to get pyodbc installed in my computer.
I have python 3.6.1
The link
http://support.esri.com/en/technical-article/000011656
pointed me to another link
https://github.com/mkleehammer/pyodbc
Which is vague.
I'm used to downloading and running an exe for install.
This link is unclear and says all I have to do is:
"pip install pyodbc"
What exactly do I need to do to get this working?
Since you have not mentioned which OS you are using,
I will assume that you are on windows (as you have mentioned that you are used to install using .exe).
Firstly you need to know what a pip is:
pip is basically a package manager for python packages used to install 3 rd party packages which do not bundle along with the python distribution.
On linux pip comes pre installed also if you are using python version 3.4 onwards or python 2.7.9 you will be having pip pre installed on your system.
All you have to do it to open the command prompt issue the command
pip install package-name(pyobdc here)
it will do the job.
If you do not find pip in your distribution you can refer this link
How do I install pip on Windows?
open cmd in your computer and type
pip install pyobdc
Hello there and welcome to python programming. Basically python comes with its package installer so either you can go to any interpreter that you are using and type pip install pyobdc or use the command prompt in windows and type in pip install pyobdc. This would install your module and just remember to put import pyobdc at the top of the code if you want to use this package. Further information can be found on here
I just got a new machine (osx-lion), and I'm in the process of trying to reinstall all of my tools. I'm trying to install NumPy and SciPy. I know that the version Apple ships isn't exactly what makes NumPy and SciPy happy, so I went to Python.org and installed the recommended version (2.7.3), which went smoothly. Now when I which python, it points to the new 2.7 version which was different than the one the machine came with. My PATH variable also contains the path to the 2.7 (python.org) version.
Then I downloaded NumPy and got the message:
numpy 1.6.1 cannot be installed on this disk. numpy requires python.org Python 2.6 to install.
So then I tried SciPy, and got the same message:
scipy 0.10.1 can't be installed on this disk. scipy requires python.org Python 2.6 to install.
After some googling, I see that the 2.6 required is just 2.6 or or greater, and I did install the Python.org version (2.7), but I must be missing something.
Edit - Just tried rebooting the machine in case there were some changes that needed a restart to take effect, but that didn't help.
Any help would be greatly appreciated. Thanks all.
A simple and easy way to install numpy and scipy without going through version conflicts is to use the Enthought python distribution. They have a free version that includes python and the two packages you want, and the iPython console that I like a lot. They also offer a more extensive distribution that is free only for academic use, otherwise you have to pay for it.
python.org recommends installing an updated version of python 2.x instead of the version that comes with OSX. Following this advice, I was able to get scipy and numpy to work without enthought. Here are the versions that I am using (some version numbers missing, my notes are not complete):
Python 2.7.2 from python.org (64 bit)
numpy/scipy (OSX 10.6 build)
ipython 0.12
readline
matplotlib
At the end of the day, enthought.com is the easiest way to install everything.
Install latest version of Xcode/devtools and fortran ( http://www.scipy.org/Installing_SciPy/Mac_OS_X ).
Confirm python version
python --version
Install pip
sudo easy_install pip
Install numpy
sudo pip install numpy
If it complains you have an older version of bumpy installed, upgrade it.
pip install numpy --upgrade
check how many tests it fails ;)
sudo pip install nose
python
import numpy as np
np.test('full')
If you have the OSX developer tools installed, you should be able to install from source without much trouble.
make sure you have setuptools/distribute installed in your Python.org installation: run distribute_setup.py from the new python
make sure you have the gfortran compiler for scipy. This is just brew install gfortran if you use Homebrew.
use the right easy_install to just do easy_install numpy; easy_install scipy. (Or, easy_install pip and then pip install numpy; pip install scipy.)
im not exactly sure how osx works, but if it prompts you for a directory select the one in which you installed python 2.7
you could also download numpy for 2.6 here: (via sourceforge)
http://sourceforge.net/projects/numpy/files/NumPy/1.6.1/numpy-1.6.1-py2.6-python.org-macosx10.3.dmg/download
note: i was searching for a scipy for 2.6 when i came across this on their website:
"Note that the Mac OS X binaries work with the Python from python.org, not with the Python provided by Apple. "
I suggest using the superpack by https://twitter.com/fonnesbeck you can find the install script here http://fonnesbeck.github.io/ScipySuperpack/
Enthought's canopy is a lot of money for software they did not build themselves.
from this site
http://matplotlib.sourceforge.net/users/installing.html#installing-from-source
tell us that the requirement is python 2.4 or later but not python3.
Now im working with python3 and i need some plot form matplotlib.
So how to solve it?
I'm sorry, but at the current time it's not supported.
If you feel brave, you can try with the Py3k SVN branch which reportedly works with a simple example. Be aware that there has been no update in the last 8 months on this though.
Of course, you'd be more than welcome to contribute to the porting to Python 3 if you could.
You could try the unofficial versions. Check this site:
http://www.lfd.uci.edu/~gohlke/pythonlibs/
Looking at the docs at the link it says the following is a dependency:
Python (>= 2.7 or >= 3.4)
You can download a version of Python that will work at:
https://www.python.org/downloads/windows/
I would go with the most recent release and a 64 bit version as certain libraries for data analysis do not run on the 32 bit version of Python.
The version of Python you download will come with pip which you can then use to install any libraries you need to do your work.
Make sure you have set your environment variables if you want to run your programs from the command line or bash terminal.
I installed matplotlib through the bash terminal with:
pip install matplotlib
Let me know if that helps.
To install matplotlib on windows, first, you have to install pip first to install pip on windows go to website
https://pip.pypa.io/en/stable/installing/#do-i-need-to-install-pip
Download get-pip.py, being careful to save it as a .py file rather than .txt. Then, run it from the command prompt:
python get-pip.py
if pip is already installed, install matplotlib by writing in command prompt:
python -mpip install -U pip
python -mpip install -U matplotlib