BatchPlot is a simple Unix shell script that uses gnuplot to plot all files in a specified directory. Naturally, gnuplot must be installed for the script to work.


A large number of data files can be tedious to plot manually. In the university engineering departments I've been in, MATLAB is often used to automate the process. However, the MATLAB software package is quite expensive and doesn't always produce the most visually pleasing results (in my opinion). It also does not save graphics in the eps vector image format, which is the default graphics format for the popular LaTeX typesetting system. For these reasons, I wrote a script that would automate gnuplot plotting for multiple files.

System Requirements

BatchPlot requires gnuplot and a Unix or Linux system that can run Bourne shell scripts.


To use, first download the archive and extract it using the archiving tool of your choice, or cd to the directory and run:

tar xzvf batchplot0-1.tar.gz

The file in the root directory contains the program.

Some example files are contained within the example folder. Try typing:

./ -d 'example/' -f 'SPE' -l ',' -n '0844' -s 10 -e 1010 -x 'nm' -y 'dBm'

This command plots all the files in directory 'example/' with file extension 'SPE' and with file names starting with '0844'. These files contain data organized with comma deliminators, and the data starts from line 10 and ends on line 1010 with an x-axis label value of 'nm' and a y-axis label value of 'dBm'. The full insctructions can be viewed by typing:

./ -h


BatchPlot Ver. 0.1
This work is licensed under the MIT License.
Please feel free to submit issues to my email. I will open up a github page for this program if there is interest from the community to improve upon it.