7 #ifndef GAUDICOMMONSVC_AXIS_H 8 #define GAUDICOMMONSVC_AXIS_H 1 15 #include "AIDA/IAxis.h" 29 class Axis :
public AIDA::IAxis {
32 if ( index == AIDA::IAxis::OVERFLOW_BIN )
return nbins + 1;
33 if ( index == AIDA::IAxis::UNDERFLOW_BIN )
return 0;
38 if ( index ==
bins + 1 )
return AIDA::IAxis::OVERFLOW_BIN;
39 if ( index == 0 )
return AIDA::IAxis::UNDERFLOW_BIN;
91 int bins()
const override {
return taxis().GetNbins(); }
135 Axis&
me()
const {
return const_cast<Axis&>( *
this ); }
143 #endif // GAUDICOMMONSVC_AXIS_H int aIndex(int index) const
Convert a ROOT bin number on the axis to the AIDA bin number.
int coordToIndex(double coord) const override
Convert a coordinate on the axis to a bin number.
double binLowerEdge(int index) const override
Get the lower edge of the specified bin.
static int toAidaIndex(int index, int bins)
bool isFixedBinning() const override
Check if the IAxis has fixed binning, i.e.
double binUpperEdge(int index) const override
Get the upper edge of the specified bin.
double lowerEdge() const override
Get the lower edge of the IAxis.
double binWidth(int index) const override
Get the width of the specified bin.
int bins() const override
The number of bins (excluding underflow and overflow) on the IAxis.
void initialize(TAxis *itaxi, bool)
static int toRootIndex(int index, int nbins)
int rIndex(int index) const
Convert a AIDA bin number on the axis to the ROOT bin number.
Header file for std:chrono::duration-based Counters.
An IAxis represents a binned histogram axis.
double upperEdge() const override
Get the upper edge of the IAxis.