#!/bin/bash # $1 - Location of data files that where processed and need plotted. # $2 - Location of outputs files. #rm ~zacherym/public_html/plots.html names=`ls $1`; for name in $names do gnufile=$2$name; echo "#!/usr/bin/gnuplot -persist" > $gnufile; echo "set title \"$2$name\"" >> $gnufile; echo "set output \"$gnufile.ps\"" >> $gnufile; echo "set ylabel \"Lift\"" >> $gnufile; echo "set xlabel \"File No\"" >> $gnufile; echo "set terminal postscript eps color enhanced" >> $gnufile; echo "set xtics 1" >> $gnufile; echo "set xzeroaxis" >> $gnufile; echo "plot \"~/research/zach/Zach/tmp/c45/changes/testFiles/$1$name\" using 1:2 t \"W-Score\" with linespoints, \"~/research/zach/Zach/tmp/c45/changes/testFiles/$1$name\" using 1:3 t \"T-Score\" with linespoints, \"~/research/zach/Zach/tmp/c45/changes/testFiles/$1$name\" using 1:4 t \"Which-Tar3\" with linespoints" >> $gnufile; chmod +x $gnufile; echo "Plotting $gnufile"; ./$gnufile epstopdf --outfile=$gnufile.pdf $gnufile.ps cp $gnufile.pdf ~/research/zach/Zach/var/ done