Setting up Gnuplot on a Mac

I wrote these directions down over a year ago, so they could be a bit out of date. I’d like a permanent record though since some of the steps are a bit tricky…

Gnuplot is used for making graphs. If you try to compile it normally you will get some errors. Here is how to make it work:

  1. Download and install aquaterm – this is a program which will handle the actual plotting graphics for gnuplot.
  2. Download the source code for gnpulot – I am using 4.2.3.
  3. Extract the source code somewhere (double click the file in finder or use “tar xzf FILENAME” from a terminal.
  4. Open a terminal and change to the extracted source directory.
  5. Configure the source code distribution by running: ./configure –with-readline=builtin You must use the –with-readline flag because Mac OS X comes with a bad version of this library. More details here.
  6. Build the source code by running make
  7. Install the resulting package by running make install
  8. You are done!

You can test it out by running gnuplot at the terminal and then typing plot sin(x)

One Response to “Setting up Gnuplot on a Mac”

  1. TW – Virtualization, Research, Grad School » Clustered Bar Graphs in Mac OS X Says:

    [...] previously under Linux without any problems, but to work on a Mac you need to first setup gnuplot (which can be a pain), plus you need the fig2dev utility to actually produce the final output files. Luckily, I found a [...]


Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>