Created
February 7, 2015 03:48
-
-
Save pyk/8a347d14f1114c652f4b to your computer and use it in GitHub Desktop.
gnuplot template
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# The graph title | |
set title "Request time benchmark by pyk at github" | |
# legend/key | |
set key right top | |
# label x & y axis | |
set xlabel "requests" | |
set ylabel "ttime (ms)" | |
# style | |
set term png truecolor size 1024,768 enhanced font 'Courier,10' | |
set size 1,1 | |
set grid y | |
set lmargin at screen 0.1 | |
set rmargin at screen 0.95 | |
set bmargin at screen 0.1 | |
set style line 11 lc rgb "#808080" lt 1 | |
set border 3 back ls 11 | |
set tics nomirror | |
set style line 12 lc rgb "#808080" lt 0 lw 1 | |
set grid back ls 12 | |
set datafile separator "\t" | |
# set ydata time | |
# set timefmt "%S" | |
# set format y "%M:%S" | |
set xrange [0:*] | |
set yrange [0:*] | |
# ttime max & min | |
set output "/dev/null" | |
plot "mynginx4.out" using (column(0)):5 | |
ttime4_max=GPVAL_DATA_Y_MAX | |
ttime4_min=GPVAL_DATA_Y_MIN | |
ttime4_meanf(x)=ttime4_mean | |
set fit quiet | |
fit ttime4_meanf(x) "mynginx4.out" using (column(0)):5 via ttime4_mean | |
# ttime max & min | |
set output "/dev/null" | |
plot "mynginx2.out" using (column(0)):5 | |
ttime2_max=GPVAL_DATA_Y_MAX | |
ttime2_min=GPVAL_DATA_Y_MIN | |
ttime2_meanf(x)=ttime2_mean | |
set fit quiet | |
fit ttime2_meanf(x) "mynginx2.out" using (column(0)):5 via ttime2_mean | |
# ttime max & min | |
set output "/dev/null" | |
plot "mynginx3.out" using (column(0)):5 | |
ttime3_max=GPVAL_DATA_Y_MAX | |
ttime3_min=GPVAL_DATA_Y_MIN | |
ttime3_meanf(x)=ttime3_mean | |
set fit quiet | |
fit ttime3_meanf(x) "mynginx3.out" using (column(0)):5 via ttime3_mean | |
set output "benchmark.png" | |
#plot "mynginx1.out" using (column(0)):5 every ::1 with filledcurves y1=0 fs transparent solid 0.75 lc rgb "forest-green" title sprintf("ttime min=%0.0fms max=%0.0fms mean=%0.0fms", ttime_min, ttime_max, ttime_mean), \ | |
# "mynginx2.out" using (column(0)):4 every ::1 with filledcurves y1=0 fs transparent solid 0.50 lc rgb "gold" title "dtime", \ | |
# "mynginx2.out" using (column(0)):3 every ::1 with filledcurves y1=0 fs transparent solid 0.25 lc rgb "red" title "ctime" | |
plot "mynginx4.out" using (column(0)):5 every ::4 with filledcurves y1=0 fs transparent solid 0.75 lc rgb "forest-green" title sprintf("nginx min=%0.0fms max=%0.0fms mean=%0.0fms", ttime4_min, ttime4_max, ttime4_mean), \ | |
"mynginx2.out" using (column(0)):5 every ::1 with filledcurves y1=0 fs transparent solid 0.50 lc rgb "gold" title sprintf("nginx min=%0.0fms max=%0.0fms mean=%0.0fms", ttime2_min, ttime2_max, ttime2_mean), \ | |
"mynginx3.out" using (column(0)):5 every ::1 with filledcurves y1=0 fs transparent solid 0.25 lc rgb "red" title sprintf("nginx min=%0.0fms max=%0.0fms mean=%0.0fms", ttime3_min, ttime3_max, ttime3_mean) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment