This Class is used to represent fitted data that is Gaussian like in nature (ie centroid and area).
Public Member Functions | |
TPeak (const TPeak ©) | |
TPeak (Double_t cent, Double_t xlow, Double_t xhigh) | |
TPeak (Double_t cent, Double_t xlow, Double_t xhigh, TF1 *background) | |
TPeak () | |
~TPeak () override | |
Bool_t | AddToGlobalList (Bool_t on=kTRUE) override |
Double_t | Area () const |
Double_t | AreaErr () const |
TF1 * | Background () const |
Double_t | Centroid () const |
Double_t | CentroidErr () const |
void | CheckArea () |
void | CheckArea (Double_t int_low, Double_t int_high) |
void | Clear (Option_t *opt="") override |
virtual void | ClearParameters (Option_t *opt="") |
void | Copy (TObject &obj) const override |
virtual void | CopyParameters (TF1 *copy) const |
void | DrawBackground (Option_t *opt="SAME") const |
void | DrawResiduals () |
Bool_t | Fit (TH1 *fitHist, Option_t *opt="") |
const TF1 * | FitFunction () const |
Double_t | FWHM () const |
Double_t | FWHMErr () const |
Double_t | GetArea () const |
Double_t | GetAreaErr () const |
Double_t | GetCentroid () const |
Double_t | GetCentroidErr () const |
const TF1 * | GetFitFunction () const |
Double_t | GetFWHM () const |
Double_t | GetFWHMErr () const |
virtual TH1 * | GetHist () const |
Double_t | GetIntegralArea () |
Double_t | GetIntegralArea (Double_t int_low, Double_t int_high) |
Double_t | GetIntegralAreaErr () |
Double_t | GetIntegralAreaErr (Double_t int_low, Double_t int_high) |
Bool_t | InitParams (TH1 *fitHist=nullptr) override |
Double_t | IntegralArea () |
Double_t | IntegralArea (Double_t int_low, Double_t int_high) |
Double_t | IntegralAreaErr () |
Double_t | IntegralAreaErr (Double_t int_low, Double_t int_high) |
Bool_t | IsGoodFit () const |
void | Print (Option_t *opt="") const override |
void | SetCentroid (Double_t cent) |
virtual void | SetHist (TH1 *hist) |
Static Public Member Functions | |
static Bool_t | AddToGlobalList (TF1 *func, Bool_t on=kTRUE) |
static Bool_t | CompareArea (const TPeak &lhs, const TPeak &rhs) |
static Bool_t | CompareArea (const TPeak *lhs, const TPeak *rhs) |
static Bool_t | CompareEnergy (const TPeak &lhs, const TPeak &rhs) |
static Bool_t | CompareEnergy (const TPeak *lhs, const TPeak *rhs) |
static const char * | GetDefaultFitType () |
static TPeak * | GetLastFit () |
static Bool_t | GetLogLikelihoodFlag () |
static void | SetDefaultFitType (const char *fitType) |
static void | SetLogLikelihoodFlag (Bool_t flag=true) |
Protected Member Functions | |
void | GoodFit (Bool_t flag=true) |
void | InitNames () |
Bool_t | IsInitialized () const |
void | SetArea (Double_t a) |
void | SetArea (Double_t a, Double_t dA) |
void | SetAreaErr (Double_t d_a) |
void | SetChi2 (Double_t chi2) |
void | SetInitialized (Bool_t flag=true) |
void | SetNdf (Double_t Ndf) |
Private Member Functions | |
bool | GoodStatus () |
Private Attributes | |
Double_t | fArea {0.} |
TF1 * | fBackground |
Double_t | fChi2 {0.} |
Double_t | fDArea {0.} |
Double_t | fNdf {0.} |
Bool_t | fOwnBgFlag {false} |
TGraph * | fResiduals |
Static Private Attributes | |
static TPeak * | fLastFit = nullptr |
static bool | fLogLikelihoodFlag = true |
Friends | |
class | TMultiPeak |
#include <TPeak.h>
|
override |
Definition at line 154 of file TPeak.cxx.
References fBackground, fOwnBgFlag, and fResiduals.
TPeak::TPeak | ( | const TPeak & | copy | ) |
Definition at line 164 of file TPeak.cxx.
References Copy(), fBackground, and fResiduals.
TPeak::TPeak | ( | Double_t | cent, |
Double_t | xlow, | ||
Double_t | xhigh | ||
) |
Definition at line 81 of file TPeak.cxx.
References TGRSIFit::AddToGlobalList(), Clear(), fBackground, fOwnBgFlag, fResiduals, InitNames(), and TGRSIFunctions::StepBG().
TPeak::TPeak | ( | Double_t | cent, |
Double_t | xlow, | ||
Double_t | xhigh, | ||
TF1 * | background | ||
) |
Definition at line 14 of file TPeak.cxx.
References TGRSIFit::AddToGlobalList(), Clear(), fBackground, fOwnBgFlag, fResiduals, InitNames(), and TGRSIFunctions::StepBG().
TPeak::TPeak | ( | ) |
Definition at line 139 of file TPeak.cxx.
References TGRSIFit::AddToGlobalList(), fBackground, fOwnBgFlag, fResiduals, InitNames(), and TGRSIFunctions::StepBG().
Referenced by Fit().
|
overrideinherited |
Definition at line 66 of file TGRSIFit.cxx.
Referenced by TMultiPeak::Copy(), TMultiPeak::TMultiPeak(), TPeak(), and TGRSIFit::~TGRSIFit().
|
staticinherited |
Definition at line 96 of file TGRSIFit.cxx.
|
inline |
Definition at line 72 of file TPeak.h.
References GetAreaErr().
|
inline |
Definition at line 94 of file TPeak.h.
References fBackground.
Referenced by GetIntegralArea(), and GetIntegralAreaErr().
|
inline |
Definition at line 69 of file TPeak.h.
References GetCentroid().
|
inline |
Definition at line 70 of file TPeak.h.
References GetCentroidErr().
void TPeak::CheckArea | ( | ) |
Definition at line 611 of file TPeak.cxx.
References DGREEN, DRED, DYELLOW, fArea, fDArea, GetIntegralArea(), GetIntegralAreaErr(), GoodStatus(), and RESET_COLOR.
void TPeak::CheckArea | ( | Double_t | int_low, |
Double_t | int_high | ||
) |
Definition at line 589 of file TPeak.cxx.
References DGREEN, DRED, DYELLOW, fArea, fDArea, GetIntegralArea(), GetIntegralAreaErr(), GoodStatus(), and RESET_COLOR.
|
override |
|
virtualinherited |
Definition at line 47 of file TGRSIFit.cxx.
Definition at line 103 of file TPeak.h.
References GetCentroid().
Definition at line 105 of file TPeak.h.
References GetCentroid().
|
override |
Definition at line 185 of file TPeak.cxx.
References TGRSIFit::Copy(), fArea, fBackground, fChi2, fDArea, fNdf, fOwnBgFlag, fResiduals, TGRSIFit::GetHist(), and TGRSIFit::SetHist().
|
virtualinherited |
Definition at line 54 of file TGRSIFit.cxx.
Referenced by TMultiPeak::Fit().
void TPeak::DrawBackground | ( | Option_t * | opt = "SAME" | ) | const |
Definition at line 460 of file TPeak.cxx.
References fBackground.
void TPeak::DrawResiduals | ( | ) |
GetHist()->GetBinError(i));// + GetParameter("Height") + 10.;
Definition at line 465 of file TPeak.cxx.
References fChi2, fResiduals, and TGRSIFit::GetHist().
Bool_t TPeak::Fit | ( | TH1 * | fitHist, |
Option_t * | opt = "" |
||
) |
Definition at line 267 of file TPeak.cxx.
References TGRSIFunctions::CheckParameterErrors(), Copy(), fArea, fBackground, fChi2, fDArea, fLastFit, fNdf, TGRSIFit::GetHist(), GetLogLikelihoodFlag(), GREEN, InitParams(), TGRSIFit::IsInitialized(), Print(), RESET_COLOR, TGRSIFit::SetHist(), TPeak(), and YELLOW.
Referenced by TGainMatch::CoarseMatch(), TGainMatch::FineMatchFast(), TAngularCorrelation::FitSlices(), GetCentroidTPeak(), and TAngularCorrelation::UpdatePeak().
|
inline |
Definition at line 79 of file TPeak.h.
References GetFitFunction().
|
inline |
Definition at line 74 of file TPeak.h.
References GetFWHMErr().
|
inline |
Definition at line 51 of file TPeak.h.
References fArea.
Referenced by TEfficiencyCal::AddPoint(), Area(), CompareArea(), TMultiPeak::Fit(), TAngularCorrelation::FitSlices(), TCalPoint::SetPoint(), and TAngularCorrelation::UpdateIndexCorrelation().
|
inline |
Definition at line 52 of file TPeak.h.
References fDArea.
Referenced by TEfficiencyCal::AddPoint(), AreaErr(), TMultiPeak::Fit(), TAngularCorrelation::FitSlices(), TCalPoint::SetPoint(), and TAngularCorrelation::UpdateIndexCorrelation().
|
inline |
Definition at line 49 of file TPeak.h.
Referenced by TEfficiencyCal::AddPoint(), Centroid(), CompareEnergy(), TMultiPeak::DrawPeaks(), TGainMatch::FineMatchFast(), TAngularCorrelation::FitSlices(), GetCentroidTPeak(), TCalPoint::SetPoint(), TEnergyCal::SetPoint(), and TAngularCorrelation::UpdateDiagnostics().
|
inline |
Definition at line 50 of file TPeak.h.
Referenced by TEfficiencyCal::AddPoint(), CentroidErr(), TCalPoint::SetPoint(), TEnergyCal::SetPoint(), and TAngularCorrelation::UpdateDiagnostics().
|
inlinestaticinherited |
Definition at line 60 of file TGRSIFit.h.
References TGRSIFit::fDefaultFitType.
|
inline |
Definition at line 64 of file TPeak.h.
Referenced by FitFunction().
|
inline |
Definition at line 53 of file TPeak.h.
Referenced by TMultiPeak::DrawPeaks(), FWHM(), and TAngularCorrelation::UpdateDiagnostics().
|
inline |
Definition at line 54 of file TPeak.h.
Referenced by FWHMErr(), and TAngularCorrelation::UpdateDiagnostics().
|
inlinevirtualinherited |
Definition at line 59 of file TGRSIFit.h.
References TGRSIFit::fHist.
Referenced by Copy(), DrawResiduals(), Fit(), TMultiPeak::Fit(), GetIntegralArea(), GetIntegralAreaErr(), GoodStatus(), TMultiPeak::InitParams(), and InitParams().
Double_t TPeak::GetIntegralArea | ( | ) |
Definition at line 515 of file TPeak.cxx.
References GoodStatus().
Referenced by CheckArea(), and IntegralArea().
Double_t TPeak::GetIntegralArea | ( | Double_t | int_low, |
Double_t | int_high | ||
) |
Definition at line 528 of file TPeak.cxx.
References Background(), TGRSIFit::GetHist(), GoodStatus(), and hist.
Double_t TPeak::GetIntegralAreaErr | ( | ) |
Definition at line 576 of file TPeak.cxx.
References GoodStatus().
Referenced by CheckArea(), and IntegralAreaErr().
Double_t TPeak::GetIntegralAreaErr | ( | Double_t | int_low, |
Double_t | int_high | ||
) |
Definition at line 552 of file TPeak.cxx.
References Background(), TGRSIFit::GetHist(), GoodStatus(), and hist.
|
inlinestatic |
|
inlinestatic |
|
inlineprotectedinherited |
Definition at line 71 of file TGRSIFit.h.
References TGRSIFit::fGoodFitFlag.
|
private |
Definition at line 502 of file TPeak.cxx.
References fChi2, and TGRSIFit::GetHist().
Referenced by CheckArea(), GetIntegralArea(), and GetIntegralAreaErr().
|
protected |
|
overridevirtual |
Implements TGRSIFit.
Definition at line 210 of file TPeak.cxx.
References TGRSIFit::GetHist(), and TGRSIFit::SetInitialized().
Referenced by Fit(), and TAngularCorrelation::FitSlices().
|
inline |
Definition at line 75 of file TPeak.h.
References GetIntegralArea().
|
inline |
Definition at line 76 of file TPeak.h.
References GetIntegralArea().
|
inline |
Definition at line 77 of file TPeak.h.
References GetIntegralAreaErr().
|
inline |
Definition at line 78 of file TPeak.h.
References GetIntegralAreaErr().
|
inlineinherited |
Definition at line 54 of file TGRSIFit.h.
References TGRSIFit::fGoodFitFlag.
|
inlineprotectedinherited |
Definition at line 69 of file TGRSIFit.h.
References TGRSIFit::fInitFlag.
Referenced by Fit(), and TMultiPeak::Fit().
|
override |
|
inlineprotected |
Definition at line 82 of file TPeak.h.
References fArea.
Referenced by TMultiPeak::Fit(), and SetArea().
|
inlineprotected |
Definition at line 84 of file TPeak.h.
References SetArea(), and SetAreaErr().
|
inlineprotected |
Definition at line 83 of file TPeak.h.
References fDArea.
Referenced by TMultiPeak::Fit(), and SetArea().
|
inlineprotected |
|
inlinestaticinherited |
Definition at line 61 of file TGRSIFit.h.
References TGRSIFit::fDefaultFitType.
|
inlinevirtualinherited |
Definition at line 55 of file TGRSIFit.h.
References TGRSIFit::fHist, and hist.
Referenced by Copy(), Fit(), and TMultiPeak::Fit().
|
inlineprotectedinherited |
Definition at line 70 of file TGRSIFit.h.
References TGRSIFit::fInitFlag.
Referenced by TMultiPeak::InitParams(), and InitParams().
|
inlinestatic |
Definition at line 100 of file TPeak.h.
References fLogLikelihoodFlag.
Referenced by TAngularCorrelation::FitSlices().
|
inlineprotected |
|
friend |
|
private |
|
private |
Definition at line 126 of file TPeak.h.
Referenced by Background(), Copy(), DrawBackground(), Fit(), TPeak(), and ~TPeak().
|
private |
Definition at line 119 of file TPeak.h.
Referenced by Clear(), Copy(), DrawResiduals(), Fit(), GoodStatus(), Print(), and SetChi2().
|
private |
Definition at line 118 of file TPeak.h.
Referenced by CheckArea(), Clear(), Copy(), Fit(), GetAreaErr(), Print(), and SetAreaErr().
|
staticprivate |
|
staticprivate |
!
Definition at line 123 of file TPeak.h.
Referenced by GetLogLikelihoodFlag(), and SetLogLikelihoodFlag().
|
private |
|
private |