
Boost : 
Subject: [boost] [histogram] Working with standard algorithms
From: Bjorn Reese (breese_at_[hidden])
Date: 20171118 16:08:51
I would like to see a better integration between boost.histogram and
standard algorithms, especially those from <numeric>. Today they do not
work together because the dereference operator of the axis iterator
returns a pair (index and content) rather than the content.
An example of where standard algorithms could be useful is calculating
the cumulative distribution of a onedimensional histogram, which ought
to be a simple as:
auto& axis = h.axis();
std:partial_sum(axis.begin(), axis.end(), axis.begin());
Another example is ranking a set of histograms based on the cosine
similarity [1] using std::inner_product().
[1] https://en.wikipedia.org/wiki/Cosine_similarity
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk