Up: Other programming issues

9.4.1 Visualizing data with gnuplot

Gnuplot is an open-source data plotting utility available on every operating system that Marsyas supports. More information (including downloads and installation instructions) can be found on the Gnuplot website.

Data in Marsyas can be plotted easily: simply write the realvec to a text file and call gnuplot on the result.

     void someFunction() {
       string filename = "dataToPlot.txt";
     	realvec data;
     // ... do whatever processing here...
       data.writeText( filename );

After compiling and running the program, the dataToPlot.txt file may be plotted with gnuplot.

     gnuplot> plot "dataToPlot.txt"