From 2ebc9c2eeaeb03df85f21f6c593e64d3b8218658 Mon Sep 17 00:00:00 2001 From: "Bjoern B. Brandenburg" Date: Sat, 24 May 2008 22:22:46 -0400 Subject: extracted the plotting tools from csvtools --- plot_dist | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100755 plot_dist (limited to 'plot_dist') diff --git a/plot_dist b/plot_dist new file mode 100755 index 0000000..18cb48c --- /dev/null +++ b/plot_dist @@ -0,0 +1,30 @@ +#!/bin/bash + +CSV1=$1 +CSV2=$2 +OUT=$3 +TITLE=$4 + +if [ ! -f "$CSV1" ] || [ ! -f "$CSV2" ] || + [ "" == "$OUT" ] ; then + echo "Usage: plot_dist " + exit 1 +fi + +gnuplot <<EOM +set terminal png picsize 1024 768 +set out '/dev/null' +plot '$CSV1' title 'distribution' with lines +replot '$CSV2' title 'distribution (cumulative)' axes x1y2 with lines +set ylabel 'probability' +set y2label 'probability (cumulative)' +set xlabel 'overhead (in us)' +set y2tics +set y2range [0.0:1.0] +set title '$TITLE' +set key top left +set out '$OUT' +replot +set out +EOM + -- cgit v1.2.2