CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
OOTMultiplicityPlotMacros.h
Go to the documentation of this file.
1 #ifndef DPGAnalysis_SiStripTools_OOTMultiplicityPlotMacros_h
2 #define DPGAnalysis_SiStripTools_OOTMultiplicityPlotMacros_h
3 
4 #include "TH1F.h"
5 
6 class TH1F;
7 class TFile;
8 class OOTResult;
9 class OOTSummary;
10 
11 OOTSummary* ComputeOOTFractionvsRun(TFile* ff, const char* itmodule, const char* ootmodule, const char* etmodule, const char* hname, OOTSummary* ootsumm=0);
12 OOTSummary* ComputeOOTFractionvsFill(TFile* ff, const char* itmodule, const char* ootmodule, const char* etmodule, const char* hname, OOTSummary* ootsumm=0);
13 OOTResult* ComputeOOTFraction(TFile* ff, const char* itmodule, const char* ootmodule, const char* etmodule, const int run, const char* hname,
14  const bool& perFill=false);
15 std::vector<int> FillingScheme(TFile* ff, const char* path, const float thr=0.);
16 std::vector<int> FillingSchemeFromProfile(TFile* ff, const char* path, const char* hname, const float thr=0.);
17 
18 class OOTResult {
19  public:
20  TH1F* hratio;
21  float ootfrac;
22  float ootfracerr;
23  float ootfracsum;
25  int ngoodbx;
26  int nfilledbx;
28  ~OOTResult() { delete hratio;}
29 };
30 
31 class OOTSummary {
32  public:
33  TH1F* hootfrac;
34  TH1F* hootfracsum;
35  TH1F* hngoodbx;
37  hootfrac = new TH1F("ootfrac","OOT fraction vs fill/run",10,0.,10.);
38  hootfrac->SetCanExtend(TH1::kXaxis);
39 
40  hootfracsum = new TH1F("ootfracsum","OOT summed fraction vs fill/run",10,0.,10.);
41  hootfracsum->SetCanExtend(TH1::kXaxis);
42 
43  hngoodbx = new TH1F("ngoodbx","Number of good BX pairs vs fill/run",10,0.,10.);
44  hngoodbx->SetCanExtend(TH1::kXaxis);
45 
46  }
48  delete hootfrac;
49  delete hootfracsum;
50  delete hngoodbx;
51  }
52 };
53 
54 #endif // DPGAnalysis_SiStripTools_OOTMultiplicityPlotMacros_h
OOTSummary * ComputeOOTFractionvsFill(TFile *ff, const char *itmodule, const char *ootmodule, const char *etmodule, const char *hname, OOTSummary *ootsumm)
OOTResult * ComputeOOTFraction(TFile *ff, const char *itmodule, const char *ootmodule, const char *etmodule, const int run, const char *hname, const bool &perFill)
std::vector< int > FillingSchemeFromProfile(TFile *ff, const char *path, const char *hname, const float thr)
std::vector< int > FillingScheme(TFile *ff, const char *path, const float thr)
OOTSummary * ComputeOOTFractionvsRun(TFile *ff, const char *itmodule, const char *ootmodule, const char *etmodule, const char *hname, OOTSummary *ootsumm)