Gnuplot histogram labels

I have one minor problem: I need the corresponding heigh value for each histogram box, but only get one. The code and the image is attached below. Thank you all in advance!

The input file has the following data structure, all in one line:

large 7995 medium 11 small 1


set terminal png
set term pngcairo dashed
set title  " Grain Size vs N of Zones"
set ylabel "N of zones"
set style fill solid 1.0
 
set yr [0.0:8500]

filename2(n) = sprintf("f_vs_a_%03.0f_25.dat", n)
outfile  (n) = sprintf("f_vs_a_%03.0f_25.png", n)


set style data histograms

do for [N=1:86] {
    set output outfile(N)
    infile = filename2(N)

    plot for [i=N:N] filename2  (i) using 2:xtic(2)  title 'large',\
         for [i=N:N] filename2  (i) using 4:xtic(4)  title 'medium',\
         for [i=N:N] filename2  (i) using 4:xtic(4)  title 'small',\
                 
       }
EOF

enter image description here



from Recent Questions - Stack Overflow https://ift.tt/3IZimvO
https://ift.tt/3p4h22I

Comments

Popular posts from this blog

Spring Elasticsearch Operations

Network Error and Timeout on Authorize.net JS

Object oriented programming concepts (OOPs)