Add histogram class and test.