YODA::EstimateStorage< AxisT > Class Template Reference EstimateStorage convenience class based on BinnedStorage. More...
Inheritance diagram for YODA::EstimateStorage< AxisT >:
Detailed Descriptiontemplate<typename... AxisT> class YODA::EstimateStorage< AxisT > EstimateStorage convenience class based on BinnedStorage.
Definition at line 74 of file BinnedEstimate.h. Member Typedef Documentation◆ BaseT
template<typename... AxisT>
Definition at line 79 of file BinnedEstimate.h. ◆ BinningT
template<typename... AxisT>
Definition at line 80 of file BinnedEstimate.h. ◆ BinT
template<typename... AxisT>
Definition at line 81 of file BinnedEstimate.h. ◆ BinType
template<typename... AxisT>
Definition at line 85 of file BinnedEstimate.h. Constructor & Destructor Documentation◆ EstimateStorage() [1/10]
template<typename... AxisT>
Nullary constructor for unique pointers etc. Definition at line 92 of file BinnedEstimate.h. ◆ EstimateStorage() [2/10]
template<typename... AxisT>
Constructor giving explicit bin edges as rvalue reference. Discrete axes have as many edges as bins. Continuous axes have bins.size()+1 edges, the last one being the upper bound of the last bin. Definition at line 100 of file BinnedEstimate.h. 101 : BaseT(Axis<AxisT>(std::move(binsEdges))...), AnalysisObject(mkTypeString<AxisT...>(), path, title) { }
◆ EstimateStorage() [3/10]
template<typename... AxisT>
Constructor giving explicit bin edges as lvalue reference. Discrete axes have as many edges as bins. Continuous axes have bins.size()+1 edges, the last one being the upper bound of the last bin. Definition at line 108 of file BinnedEstimate.h. ◆ EstimateStorage() [4/10]
template<typename... AxisT>
Constructor giving explicit bin edges as initializer list. Discrete axes have as many edges as bins. Continuous axes have bins.size()+1 edges, the last one being the upper bound of the last bin. Definition at line 116 of file BinnedEstimate.h. 117 : BaseT(Axis<AxisT>(std::move(binsEdges))...), AnalysisObject(mkTypeString<AxisT...>(), path, title) { }
◆ EstimateStorage() [5/10]
template<typename... AxisT>
template<typename EdgeT = double, typename = enable_if_all_CAxisT<EdgeT, AxisT...>>
◆ EstimateStorage() [6/10]
template<typename... AxisT>
Constructor given a binning type. Definition at line 129 of file BinnedEstimate.h. const BinningT & binning() const noexcept Returns dimension underlying binning object reference. Definition BinnedStorage.h:321 ◆ EstimateStorage() [7/10]
template<typename... AxisT>
◆ EstimateStorage() [8/10]
template<typename... AxisT>
template<typename EdgeT = double, typename = enable_if_all_CAxisT<EdgeT, AxisT...>>
◆ EstimateStorage() [9/10]
template<typename... AxisT>
Copy constructor.
Definition at line 145 of file BinnedEstimate.h. ◆ EstimateStorage() [10/10]
template<typename... AxisT>
Move constructor.
Definition at line 151 of file BinnedEstimate.h. Member Function Documentation◆ add() [1/2]
template<typename... AxisT>
Add two EstimateStorages.
Definition at line 345 of file BinnedEstimate.h. 346 {
347 if (*this != est)
348 throw BinningError("Arithmetic operation requires compatible binning!");
351 BaseT::bin(i).add(est.bin(i), pat_uncorr);
352 }
354 return *this;
355 }
void rmAnnotation(const std::string &name) Delete an annotation by name. Definition AnalysisObject.h:201 bool hasAnnotation(const std::string &name) const Check if an annotation is defined. Definition AnalysisObject.h:116 void maskBins(const std::vector< size_t > &indicesToMask, const bool status=true) noexcept Mask a range of bins. Definition BinnedStorage.h:356 size_t numBins(const bool includeOverflows=false, const bool includeMaskedBins=false) const noexcept Number of bins in the BinnedStorage. Definition BinnedStorage.h:331 References YODA::BinnedStorage< BinContentT, AxisT >::bin(), YODA::BinnedStorage< Estimate, AxisT... >::bin(), YODA::AnalysisObject::hasAnnotation(), YODA::BinnedStorage< Estimate, AxisT... >::maskBins(), YODA::BinnedStorage< BinContentT, AxisT >::maskedBins(), YODA::BinnedStorage< Estimate, AxisT... >::numBins(), and YODA::AnalysisObject::rmAnnotation(). Referenced by YODA::EstimateStorage< AxisT >::operator+=(), and YODA::EstimateStorage< AxisT >::operator+=(). ◆ add() [2/2]
template<typename... AxisT>
Add two (rvalue) EstimateStorages.
Definition at line 365 of file BinnedEstimate.h. 366 {
367 if (*this != est)
368 throw BinningError("Arithmetic operation requires compatible binning!");
371 BaseT::bin(i).add(std::move(est.bin(i)), pat_uncorr);
372 }
374 return *this;
375 }
References YODA::BinnedStorage< Estimate, AxisT... >::bin(), YODA::AnalysisObject::hasAnnotation(), YODA::BinnedStorage< Estimate, AxisT... >::maskBins(), YODA::BinnedStorage< Estimate, AxisT... >::numBins(), and YODA::AnalysisObject::rmAnnotation(). ◆ areaUnderCurve()
template<typename... AxisT>
Calculate the volume underneath the EstimateStorage.
Definition at line 506 of file BinnedEstimate.h. 508 {
509 double ret = 0.;
511 const double val = fabs(b.val());
512 const double vol = includeBinVol? b.dVol() : 1.0;
513 if (std::isfinite(vol)) ret += val*vol; // aggregate bin volume
514 }
515 return ret;
516 }
BinsVecWrapper< BinsVecT > bins(const bool includeOverflows=false, const bool includeMaskedBins=false) noexcept Returns bins vector wrapper, which skips masked elements when iterated over. Definition BinnedStorage.h:298 References YODA::BinnedStorage< Estimate, AxisT... >::bins(). Referenced by YODA::EstimateStorage< AxisT >::auc(). ◆ auc()
template<typename... AxisT>
Convenient alias for areaUnderCurve() Definition at line 519 of file BinnedEstimate.h. 521 {
523 }
double areaUnderCurve(const bool includeBinVol=true, const bool includeOverflows=false, const bool includeMaskedBins=false) const Calculate the volume underneath the EstimateStorage. Definition BinnedEstimate.h:506 References YODA::EstimateStorage< AxisT >::areaUnderCurve(). ◆ clone()
template<typename... AxisT>
Make a copy on the stack. Definition at line 155 of file BinnedEstimate.h. 155 {
157 }
EstimateStorage(const std::string &path="", const std::string &title="") Nullary constructor for unique pointers etc. Definition BinnedEstimate.h:92 ◆ covarianceMatrix()
template<typename... AxisT>
Construct a covariance matrix from the error breakdown. Definition at line 528 of file BinnedEstimate.h. 530 {
532 std::vector<std::vector<double> > covM(nBins);
533
534 // initialise cov matrix to be the right shape
535 for (size_t i = 0; i < nBins; ++i) {
536 covM[i] = std::vector<double>(nBins, 0.0);
537 }
538
540
541 // nominal-only case, i.e. total uncertainty, labelled as empty string
542 if (error_sources.size() == 1 && error_sources[0] == "") {
543 size_t i = 0;
546 ++i;
547 }
548 return covM;
549 }
550
551 // more interesting case where we actually have some uncertainty breakdown!
552 for (const std::string& sname : error_sources) {
553 if (sname == "") continue;
554 std::vector<double> systErrs(nBins, 0.0);
555 size_t i = 0;
557 if (b.hasSource(sname)) {
558 const auto& errs = b.err(sname); // dn-up pair
559 systErrs[i] = 0.5 *( fabs(errs.first)+fabs(errs.second));
560 }
561 ++i;
562 }
563 const bool skipOffDiag = (ignoreOffDiagonalTerms
564 || sname.find("STAT") != std::string::npos
565 || sname.find("UNCOR") != std::string::npos);
566 for (size_t i = 0; i < nBins; ++i) {
567 for (size_t j = 0; j < nBins; ++j) {
568 if (skipOffDiag && i != j) continue;
569 covM[i][j] += systErrs[i]*systErrs[j];
570 }
571 }
572 }
573
574 return covM;
575 }
References YODA::BinnedStorage< Estimate, AxisT... >::bins(), YODA::BinnedStorage< Estimate, AxisT... >::numBins(), YODA::EstimateStorage< AxisT >::sources(), and YODA::sqr(). ◆ deserializeContent()
template<typename... AxisT>
Content deserialisation for MPI reduce operations. Implements YODA::AnalysisObject. Definition at line 710 of file BinnedEstimate.h. 710 {
711
713 const size_t minLen = 2*nBins;
714 if (data.size() < minLen)
715 throw UserError("Length of serialized data should be at least " + std::to_string(minLen)+"!");
716
717 size_t i = 0;
718 auto itr = data.cbegin();
719 const auto itrEnd = data.cend();
720 const bool fixedLen = data.size() == 2*minLen;
721 while (itr != itrEnd) {
722 // for estimates, the first element represents the central,
723 // the subsequent value represents the number of error pairs
724 const size_t nErrs = fixedLen? 1 : (*(itr + 1) + 0.5); // add 0.5 to avoid rounding issues
725 auto last = itr + 2*(nErrs+1); // last element + 1
726 BaseT::bin(i)._deserializeContent(std::vector<double>{itr, last}, fixedLen);
727 // update for next iteration
728 itr = last;
729 ++i;
730 }
731 }
References YODA::BinnedStorage< Estimate, AxisT... >::bin(), and YODA::BinnedStorage< Estimate, AxisT... >::numBins(). ◆ dim()
template<typename... AxisT>
Total dimension of the object (number of axes + estimate) Implements YODA::AnalysisObject. Definition at line 426 of file BinnedEstimate.h. 426{ return sizeof...(AxisT) + 1; }
◆ edges()
template<typename... AxisT>
template<size_t I, typename E = typename BinningT::template getEdgeT<I>>
Templated version to get edges of axis N by value. +-inf edges are included.
Definition at line 436 of file BinnedEstimate.h. 436 {
437 return BaseT::_binning.template edges<I>(includeOverflows);
438 }
◆ lengthContent()
template<typename... AxisT>
Length of serialized content vector for MPI reduce operations. Implements YODA::AnalysisObject. Definition at line 687 of file BinnedEstimate.h. References YODA::BinnedStorage< Estimate, AxisT... >::bin(), and YODA::BinnedStorage< Estimate, AxisT... >::bins(). ◆ max()
template<typename... AxisT>
template<size_t I, typename E = typename BinningT::template getEdgeT<I>>
Get the highest non-overflow edge of the axis.
Definition at line 464 of file BinnedEstimate.h. 464 {
465 return BaseT::_binning.template max<I>();
466 }
◆ min()
template<typename... AxisT>
template<size_t I, typename E = typename BinningT::template getEdgeT<I>>
Get the lowest non-overflow edge of the axis.
Definition at line 456 of file BinnedEstimate.h. 456 {
457 return BaseT::_binning.template min<I>();
458 }
◆ mkEstimates()
template<typename... AxisT>
template<size_t axisN, typename = std::enable_if_t< (axisN < sizeof...(AxisT) && sizeof...(AxisT)>=2) >>
Split into vector of BinnedEstimates along axisN. The binning dimension of the returned objects are reduced by one unit.
Definition at line 647 of file BinnedEstimate.h. 647 {
648
649 // Need to provide a prescription for how to add the two bin contents
651 auto rtn = BaseT::template mkBinnedSlices<axisN, BinnedEstimate>(how2add, includeOverflows);
653 if (a == "Type") continue;
654 for (size_t i = 0; i < rtn.size(); ++i) {
655 rtn[i].setAnnotation(a, annotation(a));
656 }
657 }
658 for (size_t i = 0; i < rtn.size(); ++i) {
660 }
661
662 return rtn;
663 }
std::vector< std::string > annotations() const Definition AnalysisObject.h:107 const std::string & annotation(const std::string &name) const Get an annotation by name (as a string) Definition AnalysisObject.h:122 References YODA::AnalysisObject::annotation(), YODA::AnalysisObject::annotations(), and YODA::AnalysisObject::path(). ◆ mkInert()
template<typename... AxisT>
Method returns clone of the estimate with streamlined error source. Reimplemented from YODA::AnalysisObject. Definition at line 667 of file BinnedEstimate.h. 668 {
670 rtn->setPath(path);
672 if (b.numErrs() == 1) {
673 try {
674 b.renameSource("", source);
675 }
677 }
678 }
679 return rtn;
680 }
Error for problems introduced outside YODA, to put it nicely. Definition Exceptions.h:100 References YODA::BinnedStorage< BinContentT, AxisT >::bins(), YODA::EstimateStorage< AxisT >::newclone(), YODA::AnalysisObject::path(), and YODA::AnalysisObject::setPath(). ◆ mkScatter()
template<typename... AxisT>
Produce a ScatterND from a EstimateStorage. Definition at line 583 of file BinnedEstimate.h. 584 {
585
586 constexpr size_t N = sizeof...(AxisT);
587
588 ScatterND<N+1> rtn;
591 }
593
596
597 // Create the vector of coordinates
598 Utils::ndarray<double, N+1> vals;
599 // first fill bin centres, use bin index if axis non-arithmetic
601 using isContinuous = typename BinningT::template is_CAxis<I>;
602 using isArithmetic = typename BinningT::template is_Arithmetic<I>;
603 vals[I] = coordPicker<I>(b, std::integral_constant<bool, isArithmetic::value>{},
604 std::integral_constant<bool, isContinuous::value>{});
605 };
606 MetaUtils::staticFor<BinningT::Dimension::value>(indexIfDiscrete);
607 // then fill bin content
608 vals[N] = b.val();
609
610 // Create the vector of error pairs, use 0 if axis not continuous
611 Utils::ndarray<std::pair<double,double>, N+1> errs;
613 using isContinuous = typename BinningT::template is_CAxis<I>;
614 errs[I] = nullifyIfDisc<I>(b, vals[I], std::integral_constant<bool, isContinuous::value>{});
615 };
616 MetaUtils::staticFor<BinningT::Dimension::value>(nullifyDiscrete);
617 const double tot = b.quadSum().second; // use positive error component
618 errs[N] = { tot, tot };
619
620 // Add the PointND
621 rtn.addPoint( PointND<N+1>(vals, errs) );
622 }
623
624 // Decorate output scatter with the discrete edges
627 using isContinuous = typename BinningT::template is_CAxis<I>;
628 if constexpr( !isContinuous::value ) {
630 if (axis.numBins()) {
631 std::stringstream ss;
632 axis._renderYODA(ss);
633 rtn.setAnnotation("EdgesA" + std::to_string(I+1), ss.str());
634 }
635 }
636 };
637 MetaUtils::staticFor<BinningT::Dimension::value>(decorateEdges);
638
639 return rtn;
640 }
std::vector< double > vals(const bool includeOverflows=false, const bool includeMaskedBins=false) const Get list of central values. Definition BinnedEstimate.h:475 typename std::conjunction< std::is_floating_point< EdgeT >... > all_CAxes Definition BinningUtils.h:18 References YODA::ScatterND< N >::addPoint(), YODA::AnalysisObject::annotation(), YODA::AnalysisObject::annotations(), YODA::BinnedStorage< Estimate, AxisT... >::binning(), YODA::BinnedStorage< Estimate, AxisT... >::bins(), YODA::AnalysisObject::path(), YODA::AnalysisObject::setAnnotation(), and YODA::EstimateStorage< AxisT >::vals(). ◆ newclone()
template<typename... AxisT>
Make a copy on the heap. Implements YODA::AnalysisObject. Definition at line 160 of file BinnedEstimate.h. Referenced by YODA::EstimateStorage< AxisT >::mkInert(). ◆ operator+=() [1/2]
template<typename... AxisT>
Definition at line 357 of file BinnedEstimate.h. 357 {
359 }
EstimateStorage & add(const EstimateStorage &est, const std::string &pat_uncorr="^stat|^uncor") Add two EstimateStorages. Definition BinnedEstimate.h:345 References YODA::EstimateStorage< AxisT >::add(). ◆ operator+=() [2/2]
template<typename... AxisT>
Definition at line 377 of file BinnedEstimate.h. References YODA::EstimateStorage< AxisT >::add(). ◆ operator-=() [1/2]
template<typename... AxisT>
Definition at line 398 of file BinnedEstimate.h. 398 {
400 }
EstimateStorage & subtract(const EstimateStorage &est, const std::string &pat_uncorr="^stat|^uncor") Subtract one EstimateStorages from another one. Definition BinnedEstimate.h:386 References YODA::EstimateStorage< AxisT >::subtract(). ◆ operator-=() [2/2]
template<typename... AxisT>
Definition at line 415 of file BinnedEstimate.h. References YODA::EstimateStorage< AxisT >::subtract(). ◆ operator=() [1/2]
template<typename... AxisT>
Copy assignment. Definition at line 324 of file BinnedEstimate.h. 324 {
325 if (this != &est) {
326 AnalysisObject::operator = (est);
327 BaseT::operator = (est);
328 }
329 return *this;
330 }
virtual AnalysisObject & operator=(const AnalysisObject &ao) noexcept Default copy assignment operator. Definition AnalysisObject.h:61 BinnedStorage & operator=(const BinnedStorage &other) noexcept Copy assignment. Definition BinnedStorage.h:481 References YODA::AnalysisObject::operator=(), and YODA::BinnedStorage< Estimate, AxisT... >::operator=(). ◆ operator=() [2/2]
template<typename... AxisT>
Move assignment. Definition at line 333 of file BinnedEstimate.h. 333 {
334 if (this != &est) {
335 AnalysisObject::operator = (est);
336 BaseT::operator = (std::move(est));
337 }
338 return *this;
339 }
References YODA::AnalysisObject::operator=(), and YODA::BinnedStorage< Estimate, AxisT... >::operator=(). ◆ rebin() [1/2]
template<typename... AxisT>
template<size_t axisN>
Overloaded alias for rebinTo. Definition at line 314 of file BinnedEstimate.h. 314 {
315 rebinTo<axisN>(std::move(newedges));
316 }
◆ rebin() [2/2]
template<typename... AxisT>
template<size_t axisN>
Overloaded alias for rebinBy. Definition at line 281 of file BinnedEstimate.h. 281 {
282 rebinBy<axisN>(n, begin, end);
283 }
◆ rebinBy()
template<typename... AxisT>
template<size_t axisN>
Merge every group of n bins, from start to end inclusive. If the number of bins is not a multiple of n, the last m < n bins on the RHS will also be merged, as the closest possible approach to factor
Definition at line 265 of file BinnedEstimate.h. 265 {
266 if (n < 1) throw UserError("Rebinning requested in groups of 0!");
267 if (!begin) throw UserError("Visible bins start with index 1!");
269 for (size_t m = begin; m < end; ++m) {
272 if (myend > m) {
273 BaseT::template mergeBins<axisN>({m, myend});
274 end -= myend-m; //< reduce upper index by the number of removed bins
275 }
276 }
277 }
size_t numBinsAt(const size_t axisN, const bool includeOverflows=false) const noexcept Number of bins in the BinnedStorage. Definition BinnedStorage.h:339 References YODA::BinnedStorage< Estimate, AxisT... >::numBinsAt(). ◆ rebinTo()
template<typename... AxisT>
template<size_t axisN>
Rebin to the given list of bin edges. Definition at line 287 of file BinnedEstimate.h. 287 {
288 if (newedges.size() < 2)
289 throw UserError("Requested rebinning to an edge list which defines no bins");
290 using thisAxisT = typename BinningT::template getAxisT<axisN>;
291 using thisEdgeT = typename thisAxisT::EdgeT;
292 // get list of shared edges
293 thisAxisT& oldAxis = BaseT::_binning.template axis<axisN>();
294 const thisAxisT newAxis(std::move(newedges));
295 const std::vector<thisEdgeT> eshared = oldAxis.sharedEdges(newAxis);
296 if (eshared.size() != newAxis.edges().size())
297 throw BinningError("Requested rebinning to incompatible edges");
298 // loop over new lower bin edges (= first bin index of merge range)
299 for (size_t begin = 0; begin < eshared.size() - 1; ++begin) {
300 // find index of upper edge along old axis
301 // (subtracting 1 gives index of last bin to be merged)
302 size_t end = oldAxis.index(eshared[begin+1]) - 1;
303 // if the current edge is the last visible edge before the overflow
304 // merge the remaining bins into the overflow
305 if (begin == newAxis.numBins(true)-1) end = oldAxis.numBins(true)-1;
306 // merge this range
307 if (end > begin) BaseT::template mergeBins<axisN>({begin, end});
308 if (eshared.size() == oldAxis.edges().size()) break; // we're done
309 }
310 }
◆ reset()
template<typename... AxisT>
Reset the EstimateStorage. Keep the binning but set all bin contents and related quantities to zero Implements YODA::AnalysisObject. Definition at line 321 of file BinnedEstimate.h. 321{ BaseT::clearBins(); }
References YODA::BinnedStorage< Estimate, AxisT... >::clearBins(). ◆ scale()
template<typename... AxisT>
Rescale as if all fill weights had been different by factor scalefactor. Definition at line 248 of file BinnedEstimate.h. 248 {
251 bin.scale(scalefactor);
252 }
253 }
void setAnnotation(const std::string &name, const T &value) Add or set an annotation by name (templated for remaining types) Definition AnalysisObject.h:169 References YODA::BinnedStorage< Estimate, AxisT... >::bin(), and YODA::AnalysisObject::setAnnotation(). ◆ serializeContent()
template<typename... AxisT>
Content serialisation for MPI reduce operations. Implements YODA::AnalysisObject. Definition at line 695 of file BinnedEstimate.h. 695 {
696 std::vector<double> rtn;
698 rtn.reserve(nBins * 4);
699 for (size_t i = 0; i < nBins; ++i) {
701 std::vector<double> bdata = b._serializeContent(fixed_length);
702 rtn.insert(std::end(rtn),
703 std::make_move_iterator(std::begin(bdata)),
704 std::make_move_iterator(std::end(bdata)));
705 }
706 return rtn;
707 }
References YODA::BinnedStorage< Estimate, AxisT... >::bin(), and YODA::BinnedStorage< Estimate, AxisT... >::numBins(). ◆ sources()
template<typename... AxisT>
Get list of error sources. Definition at line 486 of file BinnedEstimate.h. 486 {
487 // Assemble union of error sources, as it's not guaranteed
488 // that every bin has the same error breakdown
489 std::vector<std::string> rtn;
490
492 std::vector<std::string> keys = b.sources();
493 rtn.insert(std::end(rtn),
494 std::make_move_iterator(std::begin(keys)),
495 std::make_move_iterator(std::end(keys)));
496 }
497 std::sort(rtn.begin(), rtn.end());
498 rtn.erase( std::unique(rtn.begin(), rtn.end()), rtn.end() );
499
500 return rtn;
501 }
References YODA::BinnedStorage< Estimate, AxisT... >::bins(). Referenced by YODA::EstimateStorage< AxisT >::covarianceMatrix(). ◆ subtract() [1/2]
template<typename... AxisT>
Subtract one EstimateStorages from another one.
Definition at line 386 of file BinnedEstimate.h. 387 {
388 if (*this != est)
389 throw BinningError("Arithmetic operation requires compatible binning!");
392 BaseT::bin(i).subtract(est.bin(i), pat_uncorr);
393 }
395 return *this;
396 }
References YODA::BinnedStorage< BinContentT, AxisT >::bin(), YODA::BinnedStorage< Estimate, AxisT... >::bin(), YODA::AnalysisObject::hasAnnotation(), YODA::BinnedStorage< Estimate, AxisT... >::maskBins(), YODA::BinnedStorage< BinContentT, AxisT >::maskedBins(), YODA::BinnedStorage< Estimate, AxisT... >::numBins(), and YODA::AnalysisObject::rmAnnotation(). Referenced by YODA::EstimateStorage< AxisT >::operator-=(), and YODA::EstimateStorage< AxisT >::operator-=(). ◆ subtract() [2/2]
template<typename... AxisT>
Subtract one (rvalue) EstimateStorages from another one. Definition at line 403 of file BinnedEstimate.h. 404 {
405 if (*this != est)
406 throw BinningError("Arithmetic operation requires compatible binning!");
409 BaseT::bin(i) -= std::move(est.bin(i), pat_uncorr);
410 }
412 return *this;
413 }
References YODA::BinnedStorage< Estimate, AxisT... >::bin(), YODA::AnalysisObject::hasAnnotation(), YODA::BinnedStorage< Estimate, AxisT... >::maskBins(), YODA::BinnedStorage< Estimate, AxisT... >::numBins(), and YODA::AnalysisObject::rmAnnotation(). ◆ vals()
template<typename... AxisT>
Get list of central values. Definition at line 475 of file BinnedEstimate.h. 476 {
477 std::vector<double> rtn;
478 rtn.reserve(BaseT::numBins(includeOverflows, includeMaskedBins));
480 rtn.push_back(b.val());
481 }
482 return rtn;
483 }
References YODA::BinnedStorage< Estimate, AxisT... >::bins(), and YODA::BinnedStorage< Estimate, AxisT... >::numBins(). Referenced by YODA::EstimateStorage< AxisT >::mkScatter(). ◆ widths()
template<typename... AxisT>
template<size_t I, typename E = typename BinningT::template getEdgeT<I>>
Templated version to get bin widths of axis N by value. Overflows are included depending on includeOverflows Needed by axis-specific version from AxisMixin
Definition at line 448 of file BinnedEstimate.h. 448 {
449 return BaseT::_binning.template widths<I>(includeOverflows);
450 }
The documentation for this class was generated from the following file:
Generated on Thu Feb 29 2024 12:47:15 for YODA - Yet more Objects for Data Analysis by 1.9.8 |