Improvements in code of histogram.