16namespace Experimental {
51 throw std::invalid_argument(
"nGroup must be > 0");
67 std::variant<std::monostate, ROperationRebin, ROperationSum>
fOperation;
Rebin the dimension, grouping a number of original bins into a new one.
ROperationRebin(std::uint64_t nGroup)
std::uint64_t GetNGroup() const
Sum bins along this dimension, effectively resulting in a projection.
Specification of a slice operation along one dimension.
RSliceSpec()=default
A default slice operation that keeps the dimension untouched.
const ROperationSum * GetOperationSum() const
RBinIndexRange fRange
The range of the slice; can be invalid to signify the full range.
std::variant< std::monostate, ROperationRebin, ROperationSum > fOperation
The operation to perform, if any.
const ROperationRebin * GetOperationRebin() const
RSliceSpec(ROperationRebin rebin)
A rebin operation of a dimension.
bool HasOperation() const
RSliceSpec(RBinIndexRange range)
A slice of a dimension.
const RBinIndexRange & GetRange() const
RSliceSpec(ROperationSum sum)
A sum operation of a dimension.
RSliceSpec(RBinIndexRange range, ROperationSum sum)
A sum operation of a slice of the dimension.
RSliceSpec(RBinIndexRange range, ROperationRebin rebin)
A rebin operation of a slice of the dimension.
static uint64_t sum(uint64_t i)