EcalTiming
 All Classes Functions Variables Pages
Public Member Functions | Private Member Functions | Private Attributes | List of all members
EcalCrystalTimingCalibration Class Reference

#include <EcalTiming/EcalTiming/interface/EcalCrystalTimingCalibration.h>

Collaboration diagram for EcalCrystalTimingCalibration:
Collaboration graph

Public Member Functions

 EcalCrystalTimingCalibration (bool weightMean=true)
 default constructor
 
float stdDev () const
 average time (mean of the time distribution) More...
 
float getMeanWithinNSigma (float sigma, float maxRange) const
 average Energy (mean of the Energy distribution) More...
 
float getStdDevWithinNSigma (float sigma, float maxRange) const
 returns the stdDev calculated within abs(mean+ n * stdDev) to reject tails
 
float getNumWithinNSigma (float sigma, float maxRange) const
 returns the num calculated within abs(mean+ n * stdDev) to reject tails
 
float getMeanErrorWithinNSigma (float sigma, float maxRange) const
 returns the error on the mean calculated within abs(mean+ n * stdDev) to reject tails
 
float getSkewnessWithinNSigma (float sigma, float maxRange) const
 returns the skewness calculated within abs(mean+ n * stdDev) to reject tails
 
bool add (EcalTimingEvent te_, bool storeEvent=true)
 add new event for this crystal
 
void dumpToTree (TTree *tree, int ix_, int iy_, int iz_, unsigned int status_, unsigned int elecID_, int iRing_)
 dump the full set of events in a TTree: need an empty tree
 
void dumpCalibToTree (TTree *tree, int rawid_, int ix_, int iy_, int iz_, unsigned int elecID_, int iRing_) const
 
bool isStableInEnergy (float min, float max, float step, std::vector< std::pair< float, EcalCrystalTimingCalibration * > > &ret)
 checks if the time measurement is stable changing the min energy threshold
 

Private Member Functions

void calcAllWithinNSigma (float n_sigma, float maxRange=10) const
 calculate sum, sum2, sum3, n for time if time within n x stdDev and store the result
 
bool insertEvent (EcalTimingEvent te_, bool storeEvent)
 

Private Attributes

float _sum
 scalar sum of the time of each timingEvent
 
float _sum2
 scalar sum of the square of the time of each timingEvent
 
unsigned long int _num
 number of timingEvents;
 
float _sumE
 scalar sum of the energy of each timingEvent: needed for average energy
 
std::map< float, float > _sumEWithinNSigma
 variables for calculation of mean, stdDev within n-times the origina stdDev (to remove tails)
 
std::map< float, unsigned int > _numWithinNSigma
 variables for calculation of mean, stdDev within n-times the origina stdDev (to remove tails)
 
std::vector< EcalTimingEventtimingEvents
 vector containing all the events for this crystal
 

Detailed Description

Description: add a description here This class contains all the timing information for a single crystal

Member Function Documentation

void EcalCrystalTimingCalibration::dumpCalibToTree ( TTree *  tree,
int  rawid_,
int  ix_,
int  iy_,
int  iz_,
unsigned int  elecID_,
int  iRing_ 
) const

dump the callibratoin to the tree

References getMeanErrorWithinNSigma(), getMeanWithinNSigma(), and getNumWithinNSigma().

Here is the call graph for this function:

float EcalCrystalTimingCalibration::getMeanWithinNSigma ( float  sigma,
float  maxRange 
) const

returns the mean time within abs(mean+ n * stdDev) to reject tails

References _numWithinNSigma, and calcAllWithinNSigma().

Referenced by dumpCalibToTree(), getSkewnessWithinNSigma(), and getStdDevWithinNSigma().

Here is the call graph for this function:

Here is the caller graph for this function:

bool EcalCrystalTimingCalibration::insertEvent ( EcalTimingEvent  te_,
bool  storeEvent 
)
inlineprivate
Todo:
weighted average by timeError

References _num, _sum, _sum2, _sumE, EcalTimingEvent::energy(), EcalTimingEvent::time(), and timingEvents.

Referenced by add().

Here is the call graph for this function:

Here is the caller graph for this function:

float EcalCrystalTimingCalibration::stdDev ( ) const
inline

< standard deviation of the time distribution

References _num, and _sum2.

Referenced by calcAllWithinNSigma(), and getSkewnessWithinNSigma().

Here is the caller graph for this function:


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