CbmRoot
Loading...
Searching...
No Matches
LmvmDraw Class Reference

#include <LmvmDraw.h>

Inheritance diagram for LmvmDraw:
[legend]
Collaboration diagram for LmvmDraw:
[legend]

Public Member Functions

 LmvmDraw ()
 
virtual ~LmvmDraw ()
 
void DrawHistFromFile (const std::string &fileName, const std::string &outputDir="", bool useMvd=true)
 Implement functionality of drawing histograms in the macro from the specified file, this function should be called from macro.
 

Private Member Functions

void RebinMinvHist ()
 Rebin minv histograms for better drawing. Should be called after calculation of S/BG ratios.
 
void SaveCanvasToImage ()
 Save all created canvases to images.
 
void DrawCutEffH1 (const std::string &hist, const std::string &option)
 
void DrawAnaStepMany (const std::string &cName, std::function< void(ELmvmAnaStep)> drawFunc)
 
void DrawPtY (const std::string &hist, ELmvmAnaStep step)
 
void DrawRapidity (ELmvmAnaStep step)
 
void DrawPtYEfficiency (ELmvmAnaStep step)
 
void DrawMinvSBg (ELmvmAnaStep step)
 
void DrawMinvBgPairSrc (ELmvmAnaStep step)
 
void DrawMinvMatching (ELmvmAnaStep step)
 
void DrawSrcAnaStepEpEmH1 (const std::string &cName, ELmvmAnaStep step)
 
void DrawMisc ()
 
void DrawSrcH1 (const std::string &hist, ELmvmAnaStep step=ELmvmAnaStep::Undefined, bool doScale=true)
 
void DrawAnaStepH1 (const std::string &hist, bool logy=false)
 
void Draw1DCut (const std::string &hist, const std::string &sigOption, double cut=-999999.)
 
void Draw2DCut (const std::string &hist, double cutCrossX=-999999., double cutCrossY=-999999.)
 
void DrawTofM2Cut ()
 
void DrawElPurity ()
 
void DrawCuts ()
 
void DrawBgSourcePairs (ELmvmAnaStep step, bool inPercent, bool drawAnaStep=true)
 
void DrawBgSourcePairsAll ()
 
void DrawAccRecVsMom ()
 
void DrawBetaMomSpectra ()
 
void Draw2DCutTriangle (double xCr, double yCr)
 
void DrawMismatchesAndGhosts ()
 
void DrawGammaVertex ()
 
void DrawMinvBg ()
 
void DrawSource2D (const std::string &cName, const std::string &hName, const std::vector< std::string > &yLabels, double scale, const std::string &zTitle)
 
void DrawBgSourceTracks ()
 
void SetAnalysisStepAxis (TH1 *h)
 
void DrawMinvPt (ELmvmAnaStep step)
 
void DrawSrcAnaStepH1 (const std::string &hName, ELmvmAnaStep step)
 
void DrawMvdCutQa ()
 
void DrawMvdAndStsHist ()
 
void DrawPmtXY ()
 
bool SkipMvd (ELmvmAnaStep step)
 
 LmvmDraw (const LmvmDraw &)
 
LmvmDrawoperator= (const LmvmDraw &)
 
 ClassDef (LmvmDraw, 1)
 

Private Attributes

Int_t fNofEvents = 0
 
bool fUseMvd = false
 
LmvmCuts fCuts
 
LmvmHist fH
 
std::string fOutputDir = ""
 

Detailed Description

Definition at line 27 of file LmvmDraw.h.

Constructor & Destructor Documentation

◆ LmvmDraw() [1/2]

LmvmDraw::LmvmDraw ( )

Definition at line 38 of file LmvmDraw.cxx.

Referenced by ClassDef(), LmvmDraw(), and operator=().

◆ ~LmvmDraw()

virtual LmvmDraw::~LmvmDraw ( )
inlinevirtual

Definition at line 32 of file LmvmDraw.h.

◆ LmvmDraw() [2/2]

LmvmDraw::LmvmDraw ( const LmvmDraw & )
private

References LmvmDraw().

Member Function Documentation

◆ ClassDef()

LmvmDraw::ClassDef ( LmvmDraw ,
1  )
private

References LmvmDraw().

◆ Draw1DCut()

void LmvmDraw::Draw1DCut ( const std::string & hist,
const std::string & sigOption,
double cut = -999999. )
private

Definition at line 259 of file LmvmDraw.cxx.

References Bg, DrawCutEffH1(), DrawH1(), DrawSrcH1(), fH, kLinear, and Signal.

Referenced by DrawCuts().

◆ Draw2DCut()

void LmvmDraw::Draw2DCut ( const std::string & hist,
double cutCrossX = -999999.,
double cutCrossY = -999999. )
private

◆ Draw2DCutTriangle()

void LmvmDraw::Draw2DCutTriangle ( double xCr,
double yCr )
private

Definition at line 357 of file LmvmDraw.cxx.

Referenced by Draw2DCut().

◆ DrawAccRecVsMom()

void LmvmDraw::DrawAccRecVsMom ( )
private

Definition at line 624 of file LmvmDraw.cxx.

References DrawH1(), DrawTextOnPad(), fH, fNofEvents, Gamma, kLinear, kLog, Cbm::NumberToString(), Pi0, and Signal.

Referenced by DrawHistFromFile().

◆ DrawAnaStepH1()

void LmvmDraw::DrawAnaStepH1 ( const std::string & hist,
bool logy = false )
private

Definition at line 533 of file LmvmDraw.cxx.

References DrawH1(), fH, kLinear, max(), min(), and SkipMvd().

Referenced by DrawMisc().

◆ DrawAnaStepMany()

void LmvmDraw::DrawAnaStepMany ( const std::string & cName,
std::function< void(ELmvmAnaStep)> drawFunc )
private

Definition at line 146 of file LmvmDraw.cxx.

References fH, and SkipMvd().

Referenced by DrawHistFromFile().

◆ DrawBetaMomSpectra()

void LmvmDraw::DrawBetaMomSpectra ( )
private

Definition at line 109 of file LmvmDraw.cxx.

References DrawH2(), fH, kLinear, and kLog.

Referenced by DrawHistFromFile().

◆ DrawBgSourcePairs()

void LmvmDraw::DrawBgSourcePairs ( ELmvmAnaStep step,
bool inPercent,
bool drawAnaStep = true )
private

Definition at line 303 of file LmvmDraw.cxx.

References DrawH2(), fH, and kLinear.

Referenced by DrawBgSourcePairsAll().

◆ DrawBgSourcePairsAll()

void LmvmDraw::DrawBgSourcePairsAll ( )
private

Definition at line 327 of file LmvmDraw.cxx.

References Acc, DrawBgSourcePairs(), DrawSource2D(), ElId, fH, Mc, and SkipMvd().

Referenced by DrawHistFromFile().

◆ DrawBgSourceTracks()

void LmvmDraw::DrawBgSourceTracks ( )
private

Definition at line 721 of file LmvmDraw.cxx.

References DrawH1(), DrawSource2D(), fH, kLinear, kLog, and SetAnalysisStepAxis().

Referenced by DrawHistFromFile().

◆ DrawCutEffH1()

void LmvmDraw::DrawCutEffH1 ( const std::string & hist,
const std::string & option )
private

Definition at line 121 of file LmvmDraw.cxx.

References DrawH1(), fH, and kLinear.

Referenced by Draw1DCut().

◆ DrawCuts()

void LmvmDraw::DrawCuts ( )
private

Definition at line 283 of file LmvmDraw.cxx.

References Draw1DCut(), Draw2DCut(), fCuts, and fUseMvd.

Referenced by DrawHistFromFile().

◆ DrawElPurity()

void LmvmDraw::DrawElPurity ( )
private

Definition at line 402 of file LmvmDraw.cxx.

References Acc, DrawH1(), DrawH2(), DrawSource2D(), DrawTextOnPad(), ElId, fH, kLinear, kLog, Mc, Cbm::NumberToString(), and y.

Referenced by DrawHistFromFile().

◆ DrawGammaVertex()

void LmvmDraw::DrawGammaVertex ( )
private

Definition at line 488 of file LmvmDraw.cxx.

References counter, DrawH1(), DrawH2(), fH, kLinear, Mc, and PtCut.

Referenced by DrawHistFromFile().

◆ DrawHistFromFile()

void LmvmDraw::DrawHistFromFile ( const std::string & fileName,
const std::string & outputDir = "",
bool useMvd = true )

Implement functionality of drawing histograms in the macro from the specified file, this function should be called from macro.

Parameters
[in]fileNameName of the input file with histograms.
[in]outputDirPath to the output directory (if it does not exist, it will be created automatically).
[in]useMvddraw histograms related to the MVD detector?
[in]drawSigDo you want to draw significance histograms?

Save old global file and folder pointer to avoid messing with FairRoot

Restore old global file and folder pointer to avoid messing with FairRoot

Definition at line 40 of file LmvmDraw.cxx.

References DrawAccRecVsMom(), DrawAnaStepMany(), DrawBetaMomSpectra(), DrawBgSourcePairsAll(), DrawBgSourceTracks(), DrawCuts(), DrawElPurity(), DrawGammaVertex(), DrawMinvBg(), DrawMinvPt(), DrawMisc(), DrawMismatchesAndGhosts(), DrawMvdAndStsHist(), DrawMvdCutQa(), DrawPmtXY(), DrawPtY(), DrawRapidity(), DrawSrcAnaStepEpEmH1(), DrawSrcAnaStepH1(), fH, fNofEvents, fOutputDir, fUseMvd, RebinMinvHist(), SaveCanvasToImage(), and SetDefaultDrawStyle().

◆ DrawMinvBg()

void LmvmDraw::DrawMinvBg ( )
private

Definition at line 367 of file LmvmDraw.cxx.

References DrawH1(), fH, kLinear, and kLog.

Referenced by DrawHistFromFile().

◆ DrawMinvBgPairSrc()

void LmvmDraw::DrawMinvBgPairSrc ( ELmvmAnaStep step)
private

Definition at line 590 of file LmvmDraw.cxx.

References Bg, DrawH1(), fH, kLinear, and Cbm::NumberToString().

◆ DrawMinvMatching()

void LmvmDraw::DrawMinvMatching ( ELmvmAnaStep step)
private

Definition at line 608 of file LmvmDraw.cxx.

References Bg, DrawH1(), fH, kLinear, and Cbm::NumberToString().

◆ DrawMinvPt()

void LmvmDraw::DrawMinvPt ( ELmvmAnaStep step)
private

Definition at line 194 of file LmvmDraw.cxx.

References DrawH2(), fH, kLinear, and Signal.

Referenced by DrawHistFromFile().

◆ DrawMinvSBg()

void LmvmDraw::DrawMinvSBg ( ELmvmAnaStep step)
private

Definition at line 562 of file LmvmDraw.cxx.

References Bg, DrawH1(), fH, kLinear, kLog, CbmDrawingOptions::MarkerStyle(), and Signal.

◆ DrawMisc()

void LmvmDraw::DrawMisc ( )
private

Definition at line 221 of file LmvmDraw.cxx.

References DrawAnaStepH1(), DrawH1(), DrawH2(), fH, kLinear, and kLog.

Referenced by DrawHistFromFile().

◆ DrawMismatchesAndGhosts()

void LmvmDraw::DrawMismatchesAndGhosts ( )
private

Definition at line 762 of file LmvmDraw.cxx.

References DrawH1(), fH, kLinear, kLog, and SetAnalysisStepAxis().

Referenced by DrawHistFromFile().

◆ DrawMvdAndStsHist()

void LmvmDraw::DrawMvdAndStsHist ( )
private

Definition at line 831 of file LmvmDraw.cxx.

References Draw2DCut(), DrawSrcH1(), fH, and fUseMvd.

Referenced by DrawHistFromFile().

◆ DrawMvdCutQa()

void LmvmDraw::DrawMvdCutQa ( )
private

Definition at line 813 of file LmvmDraw.cxx.

References DrawSrcH1(), DrawTextOnPad(), fH, and fUseMvd.

Referenced by DrawHistFromFile().

◆ DrawPmtXY()

void LmvmDraw::DrawPmtXY ( )
private

Definition at line 233 of file LmvmDraw.cxx.

References DrawH2(), DrawTextOnPad(), fH, Gamma, Pi0, and Signal.

Referenced by DrawHistFromFile().

◆ DrawPtY()

void LmvmDraw::DrawPtY ( const std::string & hist,
ELmvmAnaStep step )
private

Definition at line 166 of file LmvmDraw.cxx.

References DrawH2(), fH, kLinear, and Mc.

Referenced by DrawHistFromFile().

◆ DrawPtYEfficiency()

void LmvmDraw::DrawPtYEfficiency ( ELmvmAnaStep step)
private

Definition at line 182 of file LmvmDraw.cxx.

References Cbm::DivideH2(), DrawH2(), fH, and Mc.

◆ DrawRapidity()

void LmvmDraw::DrawRapidity ( ELmvmAnaStep step)
private

Definition at line 176 of file LmvmDraw.cxx.

References DrawH1(), fH, and kLinear.

Referenced by DrawHistFromFile().

◆ DrawSource2D()

void LmvmDraw::DrawSource2D ( const std::string & cName,
const std::string & hName,
const std::vector< std::string > & yLabels,
double scale,
const std::string & zTitle )
private

Definition at line 679 of file LmvmDraw.cxx.

References DrawH2(), fH, kLinear, kLog, SetAnalysisStepAxis(), x, and y.

Referenced by DrawBgSourcePairsAll(), DrawBgSourceTracks(), and DrawElPurity().

◆ DrawSrcAnaStepEpEmH1()

void LmvmDraw::DrawSrcAnaStepEpEmH1 ( const std::string & cName,
ELmvmAnaStep step )
private

Definition at line 207 of file LmvmDraw.cxx.

References DrawH1(), fH, Gamma, kLinear, kLog, Pi0, and Signal.

Referenced by DrawHistFromFile().

◆ DrawSrcAnaStepH1()

void LmvmDraw::DrawSrcAnaStepH1 ( const std::string & hName,
ELmvmAnaStep step )
private

Definition at line 201 of file LmvmDraw.cxx.

References DrawSrcH1(), and fH.

Referenced by DrawHistFromFile().

◆ DrawSrcH1()

void LmvmDraw::DrawSrcH1 ( const std::string & hist,
ELmvmAnaStep step = ELmvmAnaStep::Undefined,
bool doScale = true )
private

Definition at line 246 of file LmvmDraw.cxx.

References DrawH1(), fH, kLinear, kLog, and Undefined.

Referenced by Draw1DCut(), DrawMvdAndStsHist(), DrawMvdCutQa(), and DrawSrcAnaStepH1().

◆ DrawTofM2Cut()

void LmvmDraw::DrawTofM2Cut ( )
private

◆ operator=()

LmvmDraw & LmvmDraw::operator= ( const LmvmDraw & )
private

References LmvmDraw().

◆ RebinMinvHist()

void LmvmDraw::RebinMinvHist ( )
private

Rebin minv histograms for better drawing. Should be called after calculation of S/BG ratios.

Definition at line 99 of file LmvmDraw.cxx.

References fH.

Referenced by DrawHistFromFile().

◆ SaveCanvasToImage()

void LmvmDraw::SaveCanvasToImage ( )
private

Save all created canvases to images.

Definition at line 850 of file LmvmDraw.cxx.

References fH, and fOutputDir.

Referenced by DrawHistFromFile().

◆ SetAnalysisStepAxis()

void LmvmDraw::SetAnalysisStepAxis ( TH1 * h)
private

Definition at line 783 of file LmvmDraw.cxx.

References fH, fUseMvd, Mvd1Cut, Reco, SkipMvd(), x, and y.

Referenced by DrawBgSourceTracks(), DrawMismatchesAndGhosts(), and DrawSource2D().

◆ SkipMvd()

bool LmvmDraw::SkipMvd ( ELmvmAnaStep step)
private

Definition at line 94 of file LmvmDraw.cxx.

References fUseMvd, Mvd1Cut, and Mvd2Cut.

Referenced by DrawAnaStepH1(), DrawAnaStepMany(), DrawBgSourcePairsAll(), and SetAnalysisStepAxis().

Member Data Documentation

◆ fCuts

LmvmCuts LmvmDraw::fCuts
private

Definition at line 49 of file LmvmDraw.h.

Referenced by DrawCuts().

◆ fH

◆ fNofEvents

Int_t LmvmDraw::fNofEvents = 0
private

Definition at line 45 of file LmvmDraw.h.

Referenced by Draw2DCut(), DrawAccRecVsMom(), and DrawHistFromFile().

◆ fOutputDir

std::string LmvmDraw::fOutputDir = ""
private

Definition at line 52 of file LmvmDraw.h.

Referenced by DrawHistFromFile(), and SaveCanvasToImage().

◆ fUseMvd

bool LmvmDraw::fUseMvd = false
private

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