8 #include <unordered_map>
22 const std::vector<std::string>&
labels = {});
32 const std::vector<double>&
Edges()
const
40 static std::unique_ptr<Binning>
LoadFrom(TDirectory*
dir);
51 const std::vector<std::string>&
labels = {});
65 static std::map<Binning, int>&
IDMap();
Represent the binning of a Spectrum's x-axis.
bool operator<(const Binning &rhs) const
process_name opflash particleana ie x
static Binning FromTAxis(const TAxis *ax)
static std::map< Binning, int > & IDMap()
std::vector< std::string > fLabels
static Binning CustomHelper(const std::vector< double > &edges)
const Binning kTrueLOverEBins
process_name opflashCryoW ana
std::vector< double > fEdges
static int fgNextID
The next ID that hasn't yet been assigned.
bool operator==(const Binning &rhs) const
void SaveTo(TDirectory *dir) const
int FindBin(float x) const
const Binning kTrueEnergyBins
Default true-energy bin edges.
static Binning Custom(const std::vector< double > &edges)
const std::vector< double > & Edges() const
Binning TrueEnergyBins()
Default true-energy bin edges.
static Binning LogUniform(int n, double lo, double hi)
const std::vector< std::string > & Labels() const
static Binning Simple(int n, double lo, double hi, const std::vector< std::string > &labels={})
static std::unique_ptr< Binning > LoadFrom(TDirectory *dir)
static Binning SimpleHelper(int n, double lo, double hi, const std::vector< std::string > &labels={})