Logo ROOT   6.14/05
Reference Guide
List of all members | Public Types | Public Member Functions | Static Public Member Functions | Private Attributes | List of all members
ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS > Class Template Referenceabstract

template<int DIMENSIONS>
class ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >

Base class for THistImplBase that abstracts out the histogram's PRECISION.

For operations such as painting a histogram, the PRECISION (type of the bin content) is not relevant; painting will cast the underlying bin type to double. To facilitate this, THistImplBase itself inherits from the THistImplPrecisionAgnosticBase interface.

Definition at line 71 of file THistImpl.hxx.

Public Types

using AxisIterRange_t = Hist::AxisIterRange_t< DIMENSIONS >
 Range type. More...
 
using CoordArray_t = Hist::CoordArray_t< DIMENSIONS >
 Type of the coordinate: a DIMENSIONS-dimensional array of doubles. More...
 

Public Member Functions

 THistImplPrecisionAgnosticBase ()=default
 
 THistImplPrecisionAgnosticBase (const THistImplPrecisionAgnosticBase &)=default
 
 THistImplPrecisionAgnosticBase (THistImplPrecisionAgnosticBase &&)=default
 
 THistImplPrecisionAgnosticBase (std::string_view title)
 
virtual ~THistImplPrecisionAgnosticBase ()
 
virtual TAxisView GetAxis (int iAxis) const =0
 Get a TAxisView on axis with index iAxis. More...
 
virtual CoordArray_t GetBinCenter (int binidx) const =0
 Get the center in all dimensions of the bin with index binidx. More...
 
virtual double GetBinContentAsDouble (int binidx) const =0
 The bin content, cast to double. More...
 
virtual CoordArray_t GetBinFrom (int binidx) const =0
 Get the lower edge in all dimensions of the bin with index binidx. More...
 
virtual int GetBinIndex (const CoordArray_t &x) const =0
 Given the coordinate x, determine the index of the bin. More...
 
virtual int GetBinIndexAndGrow (const CoordArray_t &x)=0
 Given the coordinate x, determine the index of the bin, possibly growing axes for which x is out of range. More...
 
virtual CoordArray_t GetBinTo (int binidx) const =0
 Get the upper edge in all dimensions of the bin with index binidx. More...
 
virtual double GetBinUncertainty (int binidx) const =0
 The bin's uncertainty. More...
 
virtual int GetNBins () const noexcept=0
 Number of bins of this histogram, including all overflow and underflow bins. More...
 
virtual AxisIterRange_t GetRange (const std::array< Hist::EOverflow, DIMENSIONS > &withOverUnder) const =0
 Get a AxisIterRange_t for the whole histogram, possibly restricting the range to non-overflow bins. More...
 
const std::string & GetTitle () const
 Get the histogram title. More...
 
virtual bool HasBinUncertainty () const =0
 Whether this histogram's statistics provide storage for uncertainties, or whether uncertainties are determined as poisson uncertainty of the content. More...
 

Static Public Member Functions

static constexpr int GetNDim ()
 Number of dimensions of the coordinates. More...
 

Private Attributes

std::string fTitle
 Histogram title. More...
 

#include <ROOT/THistImpl.hxx>

Member Typedef Documentation

◆ AxisIterRange_t

template<int DIMENSIONS>
using ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::AxisIterRange_t = Hist::AxisIterRange_t<DIMENSIONS>

Range type.

Definition at line 76 of file THistImpl.hxx.

◆ CoordArray_t

template<int DIMENSIONS>
using ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::CoordArray_t = Hist::CoordArray_t<DIMENSIONS>

Type of the coordinate: a DIMENSIONS-dimensional array of doubles.

Definition at line 74 of file THistImpl.hxx.

Constructor & Destructor Documentation

◆ THistImplPrecisionAgnosticBase() [1/4]

◆ THistImplPrecisionAgnosticBase() [2/4]

template<int DIMENSIONS>
ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::THistImplPrecisionAgnosticBase ( const THistImplPrecisionAgnosticBase< DIMENSIONS > &  )
default

◆ THistImplPrecisionAgnosticBase() [3/4]

◆ THistImplPrecisionAgnosticBase() [4/4]

Definition at line 81 of file THistImpl.hxx.

◆ ~THistImplPrecisionAgnosticBase()

template<int DIMENSIONS>
virtual ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::~THistImplPrecisionAgnosticBase ( )
inlinevirtual

Definition at line 82 of file THistImpl.hxx.

Member Function Documentation

◆ GetAxis()

template<int DIMENSIONS>
virtual TAxisView ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::GetAxis ( int  iAxis) const
pure virtual

Get a TAxisView on axis with index iAxis.

Parameters
iAxis- index of the axis, must be 0 <= iAxis < DIMENSION

Implemented in ROOT::Experimental::Detail::THistImpl< DATA, AXISCONFIG >.

◆ GetBinCenter()

template<int DIMENSIONS>
virtual CoordArray_t ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::GetBinCenter ( int  binidx) const
pure virtual

Get the center in all dimensions of the bin with index binidx.

Implemented in ROOT::Experimental::Detail::THistImpl< DATA, AXISCONFIG >.

◆ GetBinContentAsDouble()

template<int DIMENSIONS>
virtual double ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::GetBinContentAsDouble ( int  binidx) const
pure virtual

The bin content, cast to double.

Implemented in ROOT::Experimental::Detail::THistImplBase< DATA >.

◆ GetBinFrom()

template<int DIMENSIONS>
virtual CoordArray_t ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::GetBinFrom ( int  binidx) const
pure virtual

Get the lower edge in all dimensions of the bin with index binidx.

Implemented in ROOT::Experimental::Detail::THistImpl< DATA, AXISCONFIG >.

◆ GetBinIndex()

template<int DIMENSIONS>
virtual int ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::GetBinIndex ( const CoordArray_t x) const
pure virtual

Given the coordinate x, determine the index of the bin.

◆ GetBinIndexAndGrow()

template<int DIMENSIONS>
virtual int ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::GetBinIndexAndGrow ( const CoordArray_t x)
pure virtual

Given the coordinate x, determine the index of the bin, possibly growing axes for which x is out of range.

◆ GetBinTo()

template<int DIMENSIONS>
virtual CoordArray_t ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::GetBinTo ( int  binidx) const
pure virtual

Get the upper edge in all dimensions of the bin with index binidx.

Implemented in ROOT::Experimental::Detail::THistImpl< DATA, AXISCONFIG >.

◆ GetBinUncertainty()

template<int DIMENSIONS>
virtual double ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::GetBinUncertainty ( int  binidx) const
pure virtual

The bin's uncertainty.

size() of the vector is a multiple of 2: several kinds of uncertainty, same number of entries for lower and upper.

Implemented in ROOT::Experimental::Detail::THistImpl< DATA, AXISCONFIG >.

◆ GetNBins()

template<int DIMENSIONS>
virtual int ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::GetNBins ( ) const
pure virtualnoexcept

Number of bins of this histogram, including all overflow and underflow bins.

Simply the product of all axes' number of bins.

Implemented in ROOT::Experimental::Detail::THistImplBase< DATA >.

◆ GetNDim()

template<int DIMENSIONS>
static constexpr int ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::GetNDim ( )
inlinestatic

Number of dimensions of the coordinates.

Definition at line 85 of file THistImpl.hxx.

◆ GetRange()

template<int DIMENSIONS>
virtual AxisIterRange_t ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::GetRange ( const std::array< Hist::EOverflow, DIMENSIONS > &  withOverUnder) const
pure virtual

Get a AxisIterRange_t for the whole histogram, possibly restricting the range to non-overflow bins.

Parameters
withOverUnder- specifies for each dimension whether under and overflow should be included in the returned range.

◆ GetTitle()

template<int DIMENSIONS>
const std::string& ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::GetTitle ( ) const
inline

Get the histogram title.

Definition at line 91 of file THistImpl.hxx.

◆ HasBinUncertainty()

template<int DIMENSIONS>
virtual bool ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::HasBinUncertainty ( ) const
pure virtual

Whether this histogram's statistics provide storage for uncertainties, or whether uncertainties are determined as poisson uncertainty of the content.

Implemented in ROOT::Experimental::Detail::THistImpl< DATA, AXISCONFIG >.

Member Data Documentation

◆ fTitle

template<int DIMENSIONS>
std::string ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >::fTitle
private

Histogram title.

Definition at line 130 of file THistImpl.hxx.

Libraries for ROOT::Experimental::Detail::THistImplPrecisionAgnosticBase< DIMENSIONS >:
[legend]

The documentation for this class was generated from the following file: