fixed rollover issues in histogram