Austin Schuh | 5af45eb | 2019-09-16 20:54:18 -0700 | [diff] [blame] | 1 | #!/usr/bin/gnuplot |
| 2 | |
| 3 | n=1000 #number of intervals |
| 4 | max=500. #max value |
| 5 | min=0 #min value |
| 6 | width=(max-min)/n #interval width |
| 7 | #function used to map a value to the intervals |
| 8 | hist(x,width)=width*floor(x/width)+width/2.0 |
| 9 | set boxwidth width*0.9 |
| 10 | set style fill solid 0.5 # fill style |
| 11 | |
| 12 | set logscale y |
| 13 | set yrange [0.1:] |
| 14 | set xrange [0:200] |
| 15 | |
| 16 | #count and plot |
| 17 | plot "/tmp/st_csv" u (hist($1,width)):(1.0) smooth freq w boxes, \ |
| 18 | "/tmp/pt_csv" u (hist($1,width)):(1.0) smooth freq w boxes, \ |
| 19 | "/tmp/ft_csv" u (hist($1,width)):(1.0) smooth freq w boxes |
| 20 | |
| 21 | pause -1 |
| 22 | |