Instruction to get Python Data Science working on Mac

Learn the Secret

Get  our 2 Free Books

Get these now which land directly to their inbox.
Invalid email address
(Last Updated On: December 10, 2015)

Instruction to get Python Data Science working on Mac

This was a challenge but got it running fairly quickly so here are my notes on what I did:

Install Python with Python 2.10 and Pycharm CE on OSX El Capitan

Follow basic install instructions here
Install with brew in a terminal
brew install python
For numpy:
brew tap homebrew/science
brew tap samueljohn/python
pip install nose
brew install fortran
Error: No available formula with the name “gfortran”

GNU Fortran is now provided as part of GCC, and can be installed with:

brew install gcc

brew install numpy –with-openblas

For scipy:
brew install scipy –with-openblas
Error: Formulae found in multiple taps:

* homebrew/python/numpy <- not valid when you tap

* samueljohn/python/numpy  <— not valid when you tap

Please use the fully-qualified name e.g. homebrew/python/numpy to refer the formula.

For matplotlib:

brew install matplotlib

Error: Formulae found in multiple taps:

* homebrew/python/matplotlib

* samueljohn/python/matplotlib

Please use the fully-qualified name e.g. homebrew/python/matplotlib to refer the formula.

For IPython:
brew install zeromq
pip install jinja2
pip install tornado
pip install pyzmq

For pandas
pip install pandas

For above errors in matplotlib do:
pip install matplotlib
For spicy
pip install spicy

Test it al from

run in Ipython in terminal

import numpy
import scipy
import matplotlib
import pandas

Continue IPython with qt interface

brew install pyqt

These are required but could already be installed if you did the above:

brew install zmq
pip install pyzmq
pip install pygments

To run iptyhon with qtconsole:

ipython qtconsole –pylab=inline

…ImportError: No module named qtconsole.qtconsoleapp

As explained above you may need add PTYHONPATH to ~/.bash_profile

touch ~/.bash_profile; open ~/.bash_profile

export PYTHONPATH=/usr/local/lib/python:$PYTHONPATH

Also do:
pip install qtconsole

All fixed and works with iPython

 Join my FREE newsletter to see how I plan to implement Python in to an automated trading system


NOTE I now post my TRADING ALERTS into my personal FACEBOOK ACCOUNT and TWITTER. Don't worry as I don't post stupid cat videos or what I eat!
This entry was posted in Quant Development and tagged , , , on by .

About caustic

Hi i there My name is Bryan Downing. I am part of a company called QuantLabs.Net This is specifically a company with a high profile blog about technology, trading, financial, investment, quant, etc. It posts things on how to do job interviews with large companies like Morgan Stanley, Bloomberg, Citibank, and IBM. It also posts different unique tips and tricks on Java, C++, or C programming. It posts about different techniques in learning about Matlab and building models or strategies. There is a lot here if you are into venturing into the financial world like quant or technical analysis. It also discusses the future generation of trading and programming Specialties: C++, Java, C#, Matlab, quant, models, strategies, technical analysis, linux, windows P.S. I have been known to be the worst typist. Do not be offended by it as I like to bang stuff out and put priorty of what I do over typing. Maybe one day I can get a full time copy editor to help out. Do note I prefer videos as they are much easier to produce so check out my many video at