GRSISort "v4.0.0.5"
An extension of the ROOT analysis Framework
Loading...
Searching...
No Matches
TEfficiencyCal Class Reference

Detailed Description

Definition at line 12 of file TEfficiencyCal.h.

Public Member Functions

 TEfficiencyCal ()=default
 
 TEfficiencyCal (const char *name, const char *title)
 
 TEfficiencyCal (const TEfficiencyCal &)
 
 TEfficiencyCal (TEfficiencyCal &&) noexcept=default
 
 ~TEfficiencyCal ()=default
 
void AddPoint (Double_t energy, Double_t area, Double_t dEnergy=0.0, Double_t dArea=0.0)
 
void AddPoint (TPeak *peak)
 
void Clear (Option_t *opt="") override
 
void Copy (TObject &obj) const override
 
TChannelGetChannel () const
 
virtual TF1 * GetFitFunction () const
 
TH1 * GetHist () const
 
virtual TNucleusGetNucleus () const
 
virtual Double_t GetParameter (size_t parameter) const
 
virtual std::vector< Double_t > GetParameters () const
 
Bool_t IsGroupable () const override
 
TEfficiencyCaloperator= (const TEfficiencyCal &)=default
 
TEfficiencyCaloperator= (TEfficiencyCal &&) noexcept=default
 
void Print (Option_t *opt="") const override
 
void ScaleGraph (Double_t scaleFactor)
 
Bool_t SetChannel (TChannel *chan)
 
Bool_t SetChannel (UInt_t chanNum)
 
virtual void SetFitFunction (TF1 *func)
 
virtual void SetHist (TH1 *hist)
 
virtual void SetNucleus (TNucleus *nuc, Option_t *opt="")
 
virtual void WriteToAllChannels (const std::string &mnemonic="")
 
virtual void WriteToChannel () const
 

Protected Member Functions

void InitTCal ()
 

Private Attributes

TRef fChan {nullptr}
 
TF1 * fFitFunc {nullptr}
 
TH1 * fHist {nullptr}
 
TNucleusfNuc {nullptr}
 
Double_t fScaleFactor {1.}
 
+ Inheritance diagram for TEfficiencyCal:
+ Collaboration diagram for TEfficiencyCal:

Constructor & Destructor Documentation

◆ TEfficiencyCal() [1/4]

TEfficiencyCal::TEfficiencyCal ( )
default

◆ TEfficiencyCal() [2/4]

TEfficiencyCal::TEfficiencyCal ( const char * name,
const char * title )
inline

Definition at line 15 of file TEfficiencyCal.h.

◆ TEfficiencyCal() [3/4]

TEfficiencyCal::TEfficiencyCal ( const TEfficiencyCal & copy)

Definition at line 3 of file TEfficiencyCal.cxx.

References Copy().

◆ TEfficiencyCal() [4/4]

TEfficiencyCal::TEfficiencyCal ( TEfficiencyCal && )
defaultnoexcept

◆ ~TEfficiencyCal()

TEfficiencyCal::~TEfficiencyCal ( )
default

Member Function Documentation

◆ AddPoint() [1/2]

void TEfficiencyCal::AddPoint ( Double_t energy,
Double_t area,
Double_t dEnergy = 0.0,
Double_t dArea = 0.0 )

Definition at line 38 of file TEfficiencyCal.cxx.

References TCal::GetNucleus().

Referenced by AddPoint().

◆ AddPoint() [2/2]

void TEfficiencyCal::AddPoint ( TPeak * peak)

◆ Clear()

void TEfficiencyCal::Clear ( Option_t * opt = "")
override

Definition at line 63 of file TEfficiencyCal.cxx.

References TCal::Clear(), and fScaleFactor.

◆ Copy()

void TEfficiencyCal::Copy ( TObject & obj) const
override

Definition at line 8 of file TEfficiencyCal.cxx.

References TCal::Copy(), and fScaleFactor.

Referenced by TEfficiencyCal().

◆ GetChannel()

◆ GetFitFunction()

virtual TF1 * TCal::GetFitFunction ( ) const
inlinevirtualinherited

◆ GetHist()

TH1 * TCal::GetHist ( ) const
inlineinherited

Definition at line 74 of file TCal.h.

References TCal::fHist.

◆ GetNucleus()

virtual TNucleus * TCal::GetNucleus ( ) const
inlinevirtualinherited

Reimplemented in TGainMatch.

Definition at line 76 of file TCal.h.

References TCal::fNuc.

Referenced by AddPoint(), TCal::Print(), TEnergyCal::SetNucleus(), TEnergyCal::SetPoint(), and TEnergyCal::SetPointError().

◆ GetParameter()

Double_t TCal::GetParameter ( size_t parameter) const
virtualinherited

Returns the parameter at the index parameter

Reimplemented in TCFDCal, TEnergyCal, and TTimeCal.

Definition at line 99 of file TCal.cxx.

References TCal::GetFitFunction().

Referenced by TGainMatch::FineMatch(), TGainMatch::FineMatchFast(), TCal::GetParameters(), and TGainMatch::WriteToChannel().

◆ GetParameters()

std::vector< Double_t > TCal::GetParameters ( ) const
virtualinherited

Returns all of the parameters in the current TCal.

Reimplemented in TCFDCal, TEnergyCal, and TTimeCal.

Definition at line 81 of file TCal.cxx.

References TCal::GetFitFunction(), and TCal::GetParameter().

◆ InitTCal()

void TCal::InitTCal ( )
protectedinherited

Initiallizes the TCal.

Definition at line 172 of file TCal.cxx.

References TCal::Clear(), TCal::fChan, TCal::fFitFunc, TCal::fHist, and TCal::fNuc.

Referenced by TCal::TCal(), TCal::TCal(), and TCal::TCal().

◆ IsGroupable()

Bool_t TEfficiencyCal::IsGroupable ( ) const
inlineoverridevirtual

Implements TCal.

Definition at line 32 of file TEfficiencyCal.h.

◆ operator=() [1/2]

TEfficiencyCal & TEfficiencyCal::operator= ( const TEfficiencyCal & )
default

◆ operator=() [2/2]

TEfficiencyCal & TEfficiencyCal::operator= ( TEfficiencyCal && )
defaultnoexcept

◆ Print()

void TEfficiencyCal::Print ( Option_t * opt = "") const
override

Definition at line 58 of file TEfficiencyCal.cxx.

References TCal::Print().

◆ ScaleGraph()

void TEfficiencyCal::ScaleGraph ( Double_t scaleFactor)

Definition at line 14 of file TEfficiencyCal.cxx.

References fScaleFactor.

◆ SetChannel() [1/2]

Bool_t TCal::SetChannel ( TChannel * chan)
inherited

◆ SetChannel() [2/2]

Bool_t TCal::SetChannel ( UInt_t chanNum)
inherited

Sets the channel for the calibration to the channel number channum. Returns 0 if the channel does not exist

Definition at line 109 of file TCal.cxx.

References TChannel::GetChannelByNumber(), and TCal::SetChannel().

◆ SetFitFunction()

virtual void TCal::SetFitFunction ( TF1 * func)
inlinevirtualinherited

◆ SetHist()

void TCal::SetHist ( TH1 * hist)
virtualinherited

Sets this histogram pointed to. TCal does NOT take ownership so you cannot delete this histogram as long as you want to access the hist in the TCal/write it out. I will add this functionality if I get annoyed enough with the way it is.

Reimplemented in TGainMatch.

Definition at line 129 of file TCal.cxx.

References TCal::fHist, and hist.

◆ SetNucleus()

void TCal::SetNucleus ( TNucleus * nuc,
Option_t * opt = "" )
virtualinherited

Sets the nucleus to be calibrated against

Reimplemented in TEnergyCal, and TGainMatch.

Definition at line 24 of file TCal.cxx.

References TCal::fNuc.

Referenced by TEnergyCal::SetNucleus().

◆ WriteToAllChannels()

void TCal::WriteToAllChannels ( const std::string & mnemonic = "")
virtualinherited

Writes this calibration to all channels in the current TChannel Map

Definition at line 63 of file TCal.cxx.

References TCal::GetChannel(), TChannel::GetChannelMap(), TCal::SetChannel(), and TCal::WriteToChannel().

◆ WriteToChannel()

virtual void TCal::WriteToChannel ( ) const
inlinevirtualinherited

Reimplemented in TCFDCal, TEnergyCal, TGainMatch, and TTimeCal.

Definition at line 58 of file TCal.h.

Referenced by TCal::WriteToAllChannels().

Member Data Documentation

◆ fChan

TRef TCal::fChan {nullptr}
privateinherited

This points at the TChannel.

Definition at line 82 of file TCal.h.

Referenced by TCal::Clear(), TCal::Copy(), TCal::GetChannel(), TCal::InitTCal(), and TCal::SetChannel().

◆ fFitFunc

TF1* TCal::fFitFunc {nullptr}
privateinherited

Fit function representing calibration.

Definition at line 83 of file TCal.h.

Referenced by TCal::Copy(), TCal::GetFitFunction(), TCal::InitTCal(), TCal::Print(), and TCal::SetFitFunction().

◆ fHist

TH1* TCal::fHist {nullptr}
privateinherited

Histogram that was fit by the TPeak.

Definition at line 84 of file TCal.h.

Referenced by TCal::GetHist(), TCal::InitTCal(), and TCal::SetHist().

◆ fNuc

TNucleus* TCal::fNuc {nullptr}
privateinherited

Nucleus that we are calibrating against.

Definition at line 85 of file TCal.h.

Referenced by TCal::Clear(), TCal::Copy(), TCal::GetNucleus(), TCal::InitTCal(), and TCal::SetNucleus().

◆ fScaleFactor

Double_t TEfficiencyCal::fScaleFactor {1.}
private

Definition at line 37 of file TEfficiencyCal.h.

Referenced by Clear(), Copy(), and ScaleGraph().