aboutsummaryrefslogtreecommitdiffstats
path: root/csv2graph
diff options
context:
space:
mode:
authorBjoern B. Brandenburg <bbb@cs.unc.edu>2008-05-24 22:22:46 -0400
committerBjoern B. Brandenburg <bbb@cs.unc.edu>2008-05-24 22:22:46 -0400
commit2ebc9c2eeaeb03df85f21f6c593e64d3b8218658 (patch)
tree5c0ddee0930066de3d44ac207749dd533d8f2766 /csv2graph
extracted the plotting tools from csvtools
Diffstat (limited to 'csv2graph')
-rwxr-xr-xcsv2graph23
1 files changed, 23 insertions, 0 deletions
diff --git a/csv2graph b/csv2graph
new file mode 100755
index 0000000..8f7d795
--- /dev/null
+++ b/csv2graph
@@ -0,0 +1,23 @@
1#!/bin/bash
2
3FILE=$1
4
5shift
6
7if [ ! -f "$FILE" ] ; then
8 echo "Usage: csv2graph <csv file>"
9fi
10
11CUM=`mktemp`
12DIST=`mktemp`
13OUT=`echo $FILE | sed s/csv/png/`
14
15analyze -adist -b1000 "$FILE" --csv -n -i $* > $DIST
16analyze -adist -c -b1000 "$FILE" --csv -n -i $* > $CUM
17
18if [ -s $CUM ] && [ -s $DIST ]; then
19 plot_dist $DIST $CUM $OUT "$FILE: $*"
20 rm $DIST $CUM
21else
22 echo "$FILE: Empty."
23fi