Octave has many dependencies which will be downloaded and installed prior to Octave. The entire installation process can take a few hours, but precompiled binary packages called 'bottles' are available with default options for Octave and many of its dependencies.
Octave has an experimental built-in GUI (developed using Qt lib) installed by default so that gnuplot and other tools could use it directly. Gnuplot will build with Qt support if Octave's Qt-based GUI is enabled. You do not need to install an X server in most situations. Note:
On Snow Leopard, Octave requires an X server. If you install without, Homebrew will guide you to the XQuartz project (https://xquartz.macosforge.org) where you can download this.
You might find that you need to add: