-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathGenAna.h
executable file
·144 lines (116 loc) · 2.68 KB
/
GenAna.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
#ifndef GenAna_H
#define GenAna_H
#include "TObject.h"
#include <vector>
#include <stdio.h>
#include <stdlib.h>
#include <iostream>
#include <string>
#include <TMath.h>
#include <TF1.h>
#include <TH1.h>
#include <TH2.h>
#include <THStack.h>
#include <TFile.h>
#include <TTree.h>
#include <TBranch.h>
#include <TRandom3.h>
#include <TLeaf.h>
#include <TString.h>
#include <TSystem.h>
#include <TCanvas.h>
#include <TStyle.h>
#include <TFrame.h>
#include <TLegend.h>
#include <TGraph.h>
#include <TGraphErrors.h>
#include "TLorentzVector.h"
#include <algorithm>
#include "AnaInput.h"
#include "Ntuple.h"
#include "hDraw.h"
/*
#define MAXPHO 10
#define MAXVTX 10
#define MAXGEN 20
#define MAXMU 5
*/
class GenAna : public TObject {
public:
GenAna( string datacardfile = "DataCard.txt");
~GenAna();
void ReadTree( string dataName = "0", double weight = 1., string fNamePattern = "" ) ;
bool Propagator( TLorentzVector& v, double& x, double& y, double& z, double& t, double ctaugamma = 99999999. ) ;
void InitHisto() ;
void ResetHisto() ;
void WriteHisto() ;
void OpenHisto() ;
private:
AnaInput* Input;
string hfolder ;
string plotType ;
string rfolder ;
int ProcessEvents ;
int SkipEvents ;
float genPx[MAXGEN], genPy[MAXGEN], genPz[MAXGEN], genE[MAXGEN] ;
float genVx[MAXGEN], genVy[MAXGEN], genVz[MAXGEN], genT[MAXGEN] ;
int pdgId[MAXGEN], momId[MAXGEN] ;
float jetPx[10], jetPy[10], jetPz[10], jetE[10] ;
float metPx, metPy, metE ;
int nGen, nJets, eventId ;
vector<objID> genPho ;
vector<double> v_time ;
vector<double> genXTs ;
vector<double> v_ctbgT ;
vector<double> timeCalib ;
int systType ;
// Root File for Rootuple or histograms
TFile *theFile ;
string hfName ;
// Histograms set
TH1D* h_ctbg ;
TH1D* h_ctbgT ;
TH1D* h_ctau ;
TH1D* h_Time ;
TH1D* selTime ;
TH1D* selTime1 ;
TH1D* selTime2 ;
TH1D* h_Xbeta ;
TH1D* h_XPt ;
TH1D* h_XEta ;
TH2D* hTime_Xbeta ;
TH2D* hTime_ctbgT ;
TH2D* xPt_ctbgT ;
TH1D* sel_ctbgT ;
TH1D* acc_ctbgT ;
TH1D* reco_ctbgT ;
TH1D* acc_ctbgT0 ;
TH1D* acc_ctbgT1 ;
TH1D* acc_ctbgT2 ;
TH1D* sel_XEta ;
TH1D* xPt_T1 ;
TH1D* xPt_T2 ;
TH1D* xCtau_T1 ;
TH1D* xCtau_T2 ;
TH1D* xBeta_T1 ;
TH1D* xBeta_T2 ;
TH2D* h_ctbg_RZ ;
TH2D* dt1_dt2 ;
TH2D* dt1_dt2_late ;
TH1D* h_lateXctau ;
TH1D* h_lateXctbgT ;
TH1D* h_lateXbeta ;
TH1D* h_lateXPt ;
TH1D* h_GMET ;
TH1D* h_genMET ;
TH1D* h_METRes ;
TH1D* h_METdPhi ;
TH1D* h_gen1RecoPt ;
TH1D* h_gen1Pt ;
TH1D* h_nJet ;
TH1D* h_j1Pt ;
//ClassDef(GenAna, 1);
};
//#if !defined(__CINT__)
// ClassImp(GenAna);
#endif