#include <HistoChiSquare.h>
Public Member Functions | |
T & | function () |
const T & | function () const |
HistoChiSquare (T &t, TH1 *histo, double rangeMin, double rangeMax) | |
HistoChiSquare () | |
size_t | numberOfBins () const |
double | operator() () const |
void | setHistos (TH1 *histo) |
Private Attributes | |
std::vector< double > | cont_ |
double | deltaX_ |
std::vector< double > | err_ |
size_t | nBins_ |
double | rangeMax_ |
double | rangeMin_ |
T * | t_ |
double | xMax_ |
double | xMin_ |
Definition at line 10 of file HistoChiSquare.h.
fit::HistoChiSquare< T >::HistoChiSquare | ( | ) | [inline] |
Definition at line 12 of file HistoChiSquare.h.
{ }
fit::HistoChiSquare< T >::HistoChiSquare | ( | T & | t, |
TH1 * | histo, | ||
double | rangeMin, | ||
double | rangeMax | ||
) | [inline] |
Definition at line 13 of file HistoChiSquare.h.
References fit::HistoChiSquare< T >::cont_, fit::HistoChiSquare< T >::deltaX_, fit::HistoChiSquare< T >::err_, i, fit::HistoChiSquare< T >::nBins_, fit::HistoChiSquare< T >::xMax_, and fit::HistoChiSquare< T >::xMin_.
: t_(&t), rangeMin_(rangeMin), rangeMax_(rangeMax) { nBins_ = histo->GetNbinsX(); xMin_ = histo->GetXaxis()->GetXmin(); xMax_ = histo->GetXaxis()->GetXmax(); deltaX_ =(xMax_ - xMin_) / nBins_; for(size_t i = 0; i < nBins_; ++i) { cont_.push_back( histo->GetBinContent(i+1) ); err_.push_back( histo->GetBinError(i+1) ); } }
T& fit::HistoChiSquare< T >::function | ( | ) | [inline] |
Definition at line 50 of file HistoChiSquare.h.
References fit::HistoChiSquare< T >::t_.
{ return * t_; }
const T& fit::HistoChiSquare< T >::function | ( | ) | const [inline] |
Definition at line 51 of file HistoChiSquare.h.
References fit::HistoChiSquare< T >::t_.
{ return * t_; }
size_t fit::HistoChiSquare< T >::numberOfBins | ( | ) | const [inline] |
Definition at line 41 of file HistoChiSquare.h.
References fit::HistoChiSquare< T >::deltaX_, i, fit::HistoChiSquare< T >::nBins_, fit::HistoChiSquare< T >::rangeMin_, x, and fit::HistoChiSquare< T >::xMin_.
Referenced by fit::RootMinuitResultPrinter< HistoChiSquare< T > >::print().
double fit::HistoChiSquare< T >::operator() | ( | ) | const [inline] |
Definition at line 24 of file HistoChiSquare.h.
References fit::HistoChiSquare< T >::cont_, fit::HistoChiSquare< T >::deltaX_, fit::HistoChiSquare< T >::err_, i, fit::HistoChiSquare< T >::nBins_, alignCSCRings::r, fit::HistoChiSquare< T >::rangeMin_, x, and fit::HistoChiSquare< T >::xMin_.
void fit::HistoChiSquare< T >::setHistos | ( | TH1 * | histo | ) | [inline] |
Definition at line 35 of file HistoChiSquare.h.
References fit::HistoChiSquare< T >::deltaX_, fit::HistoChiSquare< T >::nBins_, fit::HistoChiSquare< T >::xMax_, and fit::HistoChiSquare< T >::xMin_.
std::vector<double> fit::HistoChiSquare< T >::cont_ [private] |
Definition at line 57 of file HistoChiSquare.h.
Referenced by fit::HistoChiSquare< T >::HistoChiSquare(), and fit::HistoChiSquare< T >::operator()().
double fit::HistoChiSquare< T >::deltaX_ [private] |
Definition at line 56 of file HistoChiSquare.h.
Referenced by fit::HistoChiSquare< T >::HistoChiSquare(), fit::HistoChiSquare< T >::numberOfBins(), fit::HistoChiSquare< T >::operator()(), and fit::HistoChiSquare< T >::setHistos().
std::vector<double> fit::HistoChiSquare< T >::err_ [private] |
Definition at line 58 of file HistoChiSquare.h.
Referenced by fit::HistoChiSquare< T >::HistoChiSquare(), and fit::HistoChiSquare< T >::operator()().
size_t fit::HistoChiSquare< T >::nBins_ [private] |
Definition at line 55 of file HistoChiSquare.h.
Referenced by fit::HistoChiSquare< T >::HistoChiSquare(), fit::HistoChiSquare< T >::numberOfBins(), fit::HistoChiSquare< T >::operator()(), and fit::HistoChiSquare< T >::setHistos().
double fit::HistoChiSquare< T >::rangeMax_ [private] |
Definition at line 54 of file HistoChiSquare.h.
double fit::HistoChiSquare< T >::rangeMin_ [private] |
Definition at line 54 of file HistoChiSquare.h.
Referenced by fit::HistoChiSquare< T >::numberOfBins(), and fit::HistoChiSquare< T >::operator()().
T* fit::HistoChiSquare< T >::t_ [private] |
Definition at line 53 of file HistoChiSquare.h.
Referenced by fit::HistoChiSquare< T >::function().
double fit::HistoChiSquare< T >::xMax_ [private] |
Definition at line 56 of file HistoChiSquare.h.
Referenced by fit::HistoChiSquare< T >::HistoChiSquare(), and fit::HistoChiSquare< T >::setHistos().
double fit::HistoChiSquare< T >::xMin_ [private] |
Definition at line 56 of file HistoChiSquare.h.
Referenced by fit::HistoChiSquare< T >::HistoChiSquare(), fit::HistoChiSquare< T >::numberOfBins(), fit::HistoChiSquare< T >::operator()(), and fit::HistoChiSquare< T >::setHistos().