1

I have a huge file with almost 1M lines. I want to create a histogram based on the contents of the file. The values in the file would look something like this:

0.0488 
-0.0342 
0.0345  
-0.0524 
-0.0503 
-0.0556 
-0.0529 
-0.0441 
-0.0433 
-0.0439 
-0.0416 
............

The histogram should look like this (this output is unrelated to the contents above, its just an example)

[ -0.09200  -0.07200] (250) *********** 
[ -0.07200  -0.05200] ( 69) *** 
[ -0.05200  -0.03200] (938) **************************************** 
[ -0.03200  -0.01200] (889) ************************************** 
[ -0.01200   0.00800] (  0) 
[  0.00800   0.02800] (  0) 
[  0.02800   0.04800] (  0) 
[  0.04800   0.06800] (  0) 
[  0.06800   0.08800] ( 97) ***** 
[  0.08800   0.10800] ( 61) *** 
  • https://unix.stackexchange.com/editing-help – ilkkachu Sep 21 '21 at 21:46
  • 1
    Perhaps this helps? https://unix.stackexchange.com/questions/177777/drawing-a-histogram-from-a-bash-command-output – Landak Sep 21 '21 at 22:03
  • This question really has several parts.  Can you break it down into those parts?  Can you make any progress in solving any of them?  … … … … … … … … … … … … … … … … … … Please do not respond in comments; [edit] your question to make it clearer and more complete. – Scott - Слава Україні Oct 06 '21 at 05:01

0 Answers0