1
0
mirror of git://projects.qi-hardware.com/wernermisc.git synced 2024-11-15 11:36:15 +02:00

ircstat/stat: move source file and filter to a variable

This makes it easier to change it to something else.
This commit is contained in:
Werner Almesberger 2012-05-30 13:06:20 -03:00
parent bd8c84d707
commit 70b01eb3d9

View File

@ -30,15 +30,17 @@ for y in 10 11 12; do
done
done
src="<sed '\$d' _out"
gnuplot -persist <<EOF
set xtics ($t)
set grid xtics
set title "Traffic on the Qi-Hardware IRC channels"
set xlabel "Month"
set ylabel "Traffic (kbytes gzip'ed)"
plot "<sed '\$d' _out" using (\$1/1000) with lines title "#qi-hardware" lw 2, \
"<sed '\$d' _out" using (\$2/1000) with lines title "#milkymist" lw 2, \
"<sed '\$d' _out" using :((\$1+\$2)/1000) with lines title "Both" lw 2
plot "$src" using (\$1/1000) with lines title "#qi-hardware" lw 2, \
"$src" using (\$2/1000) with lines title "#milkymist" lw 2, \
"$src" using :((\$1+\$2)/1000) with lines title "Both" lw 2
set term png
set output "out.png"
replot