Boost
C++ Libraries
...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
This is an older version of Boost and was released in 2020. The current version is 1.90.0.
boost::histogram::algorithm::reduce — Shrink, crop, slice, and/or rebin axes of a histogram.
// In header: <boost/histogram/algorithm/reduce.hpp> template<typename Histogram, typename Iterable> Histogram reduce(const Histogram & hist, const Iterable & options);
Returns a new reduced histogram and leaves the original histogram untouched.
The commands rebin andshrink orslice for the same axis are automatically combined, this is not an error. Passing ashrink and aslice command for the same axis or tworebin commands triggers aninvalid_argument exception. Trying to reducing a non-reducible axis triggers aninvalid_argument exception. Histograms with non-reducible axes can still be reduced along the other axes that are reducible.
Parameters: |
|