I’m tinkering with some financial analysis scripts so when I got to looking into some useful python packages, Technical Anaysis Library popped up. The python bindings require the TA Lib (Technical Analysis Library) which on osx is available via homebrew. Now, when I originally installed I didn’t want to install it globally so I’ve got the less preferred, local install setup. This local install results in the following necessary commands to get the pip package to install correctly.
# Activate homebrew export PATH=~/homebrew/bin/:$PATH # install TA-lib brew install TA-lib # set C_INCLUDE_PATH export C_INCLUDE_PATH=~/homebrew/include/:$C_INCLUDE_PATH # set LIBRARY_PATH export LIBRARY_PATH=~/homebrew/lib/:$LIBRARY_PATH
Now that I’ve brew installed TA Lib and set the new include and library path, I can install the python bindings via pip.
# make virtualenv using virtualenv wrapper. mkvirtualenv financial pip install numpy pip install TA-Lib