I have read and followed this answer to install scipy/numpy/theano. However, it still failed on the same error of missing Fortran compiler after brew install gcc. While Home
It's depends on gcc version. Check your gcc version:
Depends: gcc-4.8-base (= 4.8.2-19ubuntu1) but 4.8.4-2ubuntu1~14.04 is to be installed
Update your gcc version: http://ubuntuhandbook.org/index.php/2013/08/install-gcc-4-8-via-ppa-in-ubuntu-12-04-13-04/