Crombie Tools
Correction< H > Class Template Reference

A rewrite of the Corrector that allows easy standalone correction application. More...

#include <Correction.h>

Public Member Functions

 Correction (std::string filename, const std::string &histname, const std::string &denom="")
 Reads in one or two histograms from a file. More...
 
 Correction (std::string filename, const char *histname, const char *denom=0)
 Reads in one or two histograms from a file. More...
 
 ~Correction ()
 
 ~Correction ()
 
double GetCorrection (const double xval, const double yval)
 Get the correction value from the histogram. More...
 
double GetCorrection (const double xval)
 
double GetCorrection (const double xval, const double yval)
 Get the correction value from the histogram. More...
 
double GetCorrection (const double xval)
 

Private Types

using minmax = std::pair< double, double >
 
using minmax = std::pair< double, double >
 

Private Member Functions

double Filter (const minmax &mm, double val)
 
double Filter (const minmax &mm, double val)
 
double get (const int bin)
 
double get (const int bin)
 

Private Attributes

H * hist
 
minmax xminmax {}
 
minmax yminmax {}
 

Detailed Description

template<typename H>
class Correction< H >

A rewrite of the Corrector that allows easy standalone correction application.

Parameters
HThe type of the histogram to read

Definition at line 36 of file old/SkimmingTools/interface/Correction.h.

Member Typedef Documentation

§ minmax [1/2]

template<typename H >
using Correction< H >::minmax = std::pair<double, double>
private

Definition at line 44 of file src/include/crombie/Correction.h.

§ minmax [2/2]

template<typename H >
using Correction< H >::minmax = std::pair<double, double>
private

Definition at line 54 of file old/SkimmingTools/interface/Correction.h.

Constructor & Destructor Documentation

§ Correction() [1/2]

template<typename H >
Correction< H >::Correction ( std::string  filename,
const char *  histname,
const char *  denom = 0 
)

Reads in one or two histograms from a file.

Both histograms must have the same binning. If two histograms are given the corrector applies the first histogram divided by the second.

Definition at line 63 of file old/SkimmingTools/interface/Correction.h.

References link::filename, and crombie_completion::files.

§ ~Correction() [1/2]

template<typename H >
Correction< H >::~Correction ( )
inline

Definition at line 45 of file old/SkimmingTools/interface/Correction.h.

§ Correction() [2/2]

template<typename H >
Correction< H >::Correction ( std::string  filename,
const std::string &  histname,
const std::string &  denom = "" 
)

Reads in one or two histograms from a file.

Both histograms must have the same binning. If two histograms are given the corrector applies the first histogram divided by the second.

Definition at line 53 of file src/include/crombie/Correction.h.

References link::filename, crombie_completion::files, Correction< H >::Filter(), Correction< H >::get(), Correction< H >::GetCorrection(), Correction< H >::hist, Correction< H >::xminmax, and Correction< H >::yminmax.

§ ~Correction() [2/2]

template<typename H >
Correction< H >::~Correction ( )
inline

Member Function Documentation

§ Filter() [1/2]

template<typename H >
double Correction< H >::Filter ( const minmax mm,
double  val 
)
private

§ Filter() [2/2]

template<typename H >
double Correction< H >::Filter ( const minmax mm,
double  val 
)
private

§ get() [1/2]

template<typename H >
double Correction< H >::get ( const int  bin)
private

§ get() [2/2]

template<typename H >
double Correction< H >::get ( const int  bin)
private

§ GetCorrection() [1/4]

template<typename H >
double Correction< H >::GetCorrection ( const double  xval,
const double  yval 
)

Get the correction value from the histogram.

§ GetCorrection() [2/4]

template<typename H >
double Correction< H >::GetCorrection ( const double  xval)

§ GetCorrection() [3/4]

template<typename H >
double Correction< H >::GetCorrection ( const double  xval,
const double  yval 
)

Get the correction value from the histogram.

Definition at line 86 of file old/SkimmingTools/interface/Correction.h.

Referenced by Correction< H >::Correction(), and Correction< H >::~Correction().

§ GetCorrection() [4/4]

template<typename H >
double Correction< H >::GetCorrection ( const double  xval)

Definition at line 91 of file old/SkimmingTools/interface/Correction.h.

Member Data Documentation

§ hist

template<typename H >
H * Correction< H >::hist
private

§ xminmax

template<typename H >
minmax Correction< H >::xminmax {}
private

§ yminmax

template<typename H >
minmax Correction< H >::yminmax {}
private

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