Rewrote analysisdata histograms and added tests.
There were a few bugs and some usability issues with the histogram
implementation in the analysisdata module. Fixing those resulted in a
rewrite of most of the code, but only a few changes outside the module.
Also added unit tests for the histogram modules. This required slight
improvements to the handling of multipoint data in the analysisdata test
framework.
Will add a few more tests for the AbstractAverageHistogram class in a
separate commit, as this requires some additional changes in the test
framework, and this commit is already quite large.
Part of issue #823.
Change-Id: I81b37ce437262e3aabc48c08b0f4faf5e6738545