Octave is free software licensed under the GNU General Public License (GPL). Assuming you have Mercurial installed on your machine you may obtain the latest development version of Octave sources with the following command. AquaTerm is a Mac OS X grahics renderer. It allows command line applications written in ObjC, C, FORTRAN, Lisp, Perl or Python to display vector graphics, text and images using a simple API. Adapters for gnuplot, PGPLOT, and PLplot exists as well. Download the appropriate Dynare package for your version of Mac OS X from the website. Install Dynare by double-clicking on the package and following the installation instructions.
Most of the time, installing things with MacPorts is pretty easy; however, I have found that GNU Octave can be a little tricky. That being said, it's still pretty easy to get Octave up and running in both Snow Leopard and Lion.
At the time of this post, here's two version of Octave to choose from: octave
(version 3.2.4) and octave-devel
(version 3.4.3). For my money, I like octave-devel
. In my brief testing with the two, the biggest difference for me was that the graphs plotted in octave-devel
looked more like their OS counterparts. With octave
, I found the scaling of elements on the graph to be different sizes and that bugged me.
To install Octave, run the following from the terminal:
And then wait...as there are a lot of things that need being compiled.
I added the gcc45
variant because one of the dependencies, atlas
, needs gcc45
to compile. This ensures that both of those are in sync.
Feel free to add other variants if you like, like X11 support or offline documentation. To get a full list, run:
When you install Octave via MacPorts, AquaTerm also gets installed. AquaTerm is basically a vector renderer which Octave can use to plot its graphs. I like AquaTerm because the graphs look really smooth and nice, like you would expect on a Mac :)
If you have installed the X11 variant, you can also choose to do the rendering from within X11. The way you control this is through the environment variable, GNUTERM
.
Set GNUTERM
to x11
when you want to do your graphing in X11 and set GNUTERM
to aqua
when you want to do your graphing in AquaTerm. You can read more about setting environment variables on StackOverflow.
If you are running Octave and wish to change the GNUTERM
there, you can do so with the setenv
function, like so.
With this, you can also compare the different rendering apps and discover which one you like more.
Point and click configuration files that cause Vagrant to automatically download and configure an Octave 4.2.2 server VM under OS X including 10.10 Yosemite, 10.11 El Capitan, 10.12 Sierra and 10.13 High Sierra. The install process pulls down Octave 4.2.2 from the repository. All software used in running this server VM is open source (Vagrant, VirtualBox, Octave). The Octave GUI and graphics will display seamlessly on the Mac via the Mac's native X-windows server, while the server runs headless. The recommended configuration ensures that by default user files written by the GUI are in a folder shared with the Mac's filesystem, and the VM suspends automatically when the user quits the GUI. Any edited files then persist in the Mac's shared folder.
A binary installer for Mavericks can be found on Octave Forge.
This installer will install all binaries for GNU Octave 3.8.0 itself and its dependencies under
And will create two entries in the Applications folder
Which will start Octave in CLI and GUI mode respectively, these are just small wrappers containing a startup script and an icon to allow launching Octave from the Finder.
If you wish to uninstall GNU Octave 3.8.0 and all other software installed by this installer you can simply move the three folders listed above to the Trash. Notice that you will need to authenticate with an administrator password to be allowed to do so.
You may need to override Gatekeeper to allow installation. You may find instructions about how to do this on this page in the section labeled 'How to open an app from a unidentified developer and exempt it from Gatekeeper'.
In short:
This installer is known to work on OS X 10.9.1, you may try, at your own risk, to use it for installing on other system versions but it is not guaranteed to work.
For best performance, variability and reliability the custom installation is suggested.
Preliminary Port Installations
sudo port install atlas +gcc5
. This can last for many hours. Do this overnight. If a prior atlas installation failed, do sudo port clean atlas
before reinstallation.sudo port install arpack -accelerate+atlas
. You can even do this after you installed Octave. The new variant become active by default.Octave Installation
sudo port install octave -accelerate+atlas
at the Terminal's command line. Octave has many dependencies which will be downloaded and installed prior to Octave. The entire installation process can take some time.octave-devel
has been replaced by octave
, see MacPorts Revision 114034.octave
are displayed by typing port variants octave
. In MacPorts 2.3.4 the variants accelerate, app, docs, fltk, gfortran, graphicsmagic, qt4gui and sound are installed by default (marked with '+' sign in port variants octave
output). If you need Java support add the new Java variant (+java). A installed Java JRE is mandatory. Go To the Oracle Java website for Download. The following command works fine: sudo port install octave -accelerate+atlas+java
graphics_toolkit('gnuplot')
in Octave before plotting. For using the nicer wxt-terminal of Gnuplot, type setenv('GNUTERM','wxt')
in Octave. To make this the standard behavior append both commands in one of Octave's startup files e.g. your ~/.octaverc
. To close the graphic window of gnuplot use the Octave command close()
to get rid of the Gnuplot instance instead of using the close button of the window.To get detailed instructions from start to end on one page, refer Hani's Omnium Gatherum.
→ Latest Octave: Version 3.8.2
The Fink project uses dpkg and APT (Debian's package management system), as well as its own frontend program, fink (which is implemented as a set of Perl modules).
Install GNU Octave using Fink:
sudo xcode-select --install
.fink install octave-qtmac
or fink install octave-qtx11
at the Terminal's command line. For those running the 64 bit version of Fink, it is recommended that octave-atlas-qtmac
or octave-atlas-qtx11
be installed instead as there are some bugs/features with Apple's vecLib for the X86_64 architecture. Octave has many dependencies which will be downloaded and installed prior to Octave. The entire installation process can take many hours.fink install control-atlas-oct382
at a terminals command line.For the doc()
function to be supported by Octave, either the unversioned octave
, octave-atlas
, or octave-ref
package must be installed. Essentially, those features used at run-time which don't have a version somewhere in the file path are included in these packages.