title: Gnuplot histogram
body: <p>I have created a histogram for some data that I have in a .dat file using the </p>
  
  <pre><code>binwidth=...
  bin(x,width)=width*floor(x/width)
  
  plot 'file' using (bin($1,binwidth) + binwidth/2):(1.0) smooth freq with boxes
  </code></pre>
  
  <p>but because my file has over 1,000,000 entries that it reads from and puts into different bins, I don't know the exact frequency/density of each bin is. I would like to know the frequency or have it write the frequency to a file possibly, does anyone know if its possible? 
  I was also wondering whether instead of frequency it was possible to plot percentage on the y-axis so example if my frequency is 50,000 and my total number is 1,000,000 then on the y-axis to have a percentage instead of the actual frequency?</p>
  
  <p>Thank you</p>