Juggler
Juggling algorithms and event processing using gaudi framework
Jug::PlotHelpers Namespace Reference

Classes

struct  Binning
 Nested binning struct for booking plots. More...
 

Functions

TH1F * bookHisto (const char *histName, const char *histTitle, const Binning &varBinning)
 book a 1D histogram More...
 
TH2F * bookHisto (const char *histName, const char *histTitle, const Binning &varXBinning, const Binning &varYBinning)
 book a 2D histogram More...
 
void fillHisto (TH1F *hist, float value, float weight=1.0)
 fill a 1D histogram More...
 
void fillHisto (TH2F *hist, float xValue, float yValue, float weight=1.0)
 fill a 2D histogram More...
 
void anaHisto (TH1D *inputHist, int j, TH1F *meanHist, TH1F *widthHist)
 extract details, i.e. mean and width of a 1D histogram and fill them into histograms More...
 
TEfficiency * bookEff (const char *effName, const char *effTitle, const Binning &varBinning)
 book a 1D efficiency plot More...
 
TEfficiency * bookEff (const char *effName, const char *effTitle, const Binning &varXBinning, const Binning &varYBinning)
 book a 2D efficiency plot More...
 
void fillEff (TEfficiency *efficiency, float value, bool status)
 fill a 1D efficiency plot More...
 
void fillEff (TEfficiency *efficiency, float xValue, float yValue, bool status)
 fill a 2D efficiency plot More...
 
TProfile * bookProf (const char *profName, const char *profTitle, const Binning &varXBinning, const Binning &varYBinning)
 book a TProfile plot More...
 
void fillProf (TProfile *profile, float xValue, float yValue, float weight=1.0)
 fill a TProfile plot More...
 

Function Documentation

◆ anaHisto()

void Jug::PlotHelpers::anaHisto ( TH1D *  inputHist,
int  j,
TH1F *  meanHist,
TH1F *  widthHist 
)

extract details, i.e. mean and width of a 1D histogram and fill them into histograms

Parameters
inputHisthistogram to investigate
jwhich bin number of meanHist and widthHist to fill
meanHisthistogram to fill the mean value of inputHist
widthHisthistogram to fill the width value of inputHist
Todo:
write specialized helper class to extract details of hists
Parameters
inputHisthistogram to investigate
jwhich bin number of meanHist and widthHist to fill
meanHisthistogram to fill the mean value of inputHist
widthHisthistogram to fill the width value of inputHist
Todo:
write specialized helper class to extract details of hists
Parameters
inputHisthistogram to investigate
jwhich bin number of meanHist and widthHist to fill
meanHisthistogram to fill the mean value of inputHist
widthHisthistogram to fill the width value of inputHist
Todo:
write specialized helper class to extract details of hists

◆ bookEff() [1/2]

TEfficiency * Jug::PlotHelpers::bookEff ( const char *  effName,
const char *  effTitle,
const Binning varBinning 
)

book a 1D efficiency plot

Parameters
effNamethe name of plot
effTitlethe title of plot
varBinningthe binning info of variable
Returns
TEfficiency pointer

◆ bookEff() [2/2]

TEfficiency * Jug::PlotHelpers::bookEff ( const char *  effName,
const char *  effTitle,
const Binning varXBinning,
const Binning varYBinning 
)

book a 2D efficiency plot

Parameters
effNamethe name of plot
effTitlethe title of plot
varXBinningthe binning info of variable at x axis
varYBinningthe binning info of variable at y axis
Returns
TEfficiency pointer

◆ bookHisto() [1/2]

TH1F * Jug::PlotHelpers::bookHisto ( const char *  histName,
const char *  histTitle,
const Binning varBinning 
)

book a 1D histogram

Parameters
histNamethe name of histogram
histTitlethe title of histogram
varBinningthe binning info of variable
Returns
histogram pointer

◆ bookHisto() [2/2]

TH2F * Jug::PlotHelpers::bookHisto ( const char *  histName,
const char *  histTitle,
const Binning varXBinning,
const Binning varYBinning 
)

book a 2D histogram

Parameters
histNamethe name of histogram
histTitlethe title of histogram
varXBinningthe binning info of variable at x axis
varYBinningthe binning info of variable at y axis
Returns
histogram pointer

◆ bookProf()

TProfile * Jug::PlotHelpers::bookProf ( const char *  profName,
const char *  profTitle,
const Binning varXBinning,
const Binning varYBinning 
)

book a TProfile plot

Parameters
profNamethe name of plot
profTitlethe title of plot
varXBinningthe binning info of variable at x axis
varYBinningthe binning info of variable at y axis
Returns
TProfile pointer

◆ fillEff() [1/2]

void Jug::PlotHelpers::fillEff ( TEfficiency *  efficiency,
float  value,
bool  status 
)

fill a 1D efficiency plot

Parameters
efficiencyplot to fill
valuevalue to fill
statusbool to denote passed or not

◆ fillEff() [2/2]

void Jug::PlotHelpers::fillEff ( TEfficiency *  efficiency,
float  xValue,
float  yValue,
bool  status 
)

fill a 2D efficiency plot

Parameters
efficiencyplot to fill
xValuex value to fill
yValuey value to fill
statusbool to denote passed or not

◆ fillHisto() [1/2]

void Jug::PlotHelpers::fillHisto ( TH1F *  hist,
float  value,
float  weight = 1.0 
)

fill a 1D histogram

Parameters
histhistogram to fill
valuevalue to fill
weightweight to fill

◆ fillHisto() [2/2]

void Jug::PlotHelpers::fillHisto ( TH2F *  hist,
float  xValue,
float  yValue,
float  weight = 1.0 
)

fill a 2D histogram

Parameters
histhistogram to fill
xValuex value to fill
yValuey value to fill
weightweight to fill

◆ fillProf()

void Jug::PlotHelpers::fillProf ( TProfile *  profile,
float  xValue,
float  yValue,
float  weight = 1.0 
)

fill a TProfile plot

Parameters
profileplot to fill
xValuexvalue to fill
yValueyvalue to fill
weightweight to fill