This repository was archived by the owner on Feb 16, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathPDAnalyzer.h
82 lines (56 loc) · 1.89 KB
/
PDAnalyzer.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
#ifndef PDAnalyzer_H
#define PDAnalyzer_H
#include "TH1.h"
#include "PDAnalyzerUtil.h"
#include "PDMuonVar.h"
#include "PDSoftMuonMvaEstimator.h"
#include "AlbertoUtil.h"
// additional features
class PDSecondNtupleWriter;
// to skim the N-tuple replace the the following line
// with the "commented" ones
class PDAnalyzer: public virtual PDAnalyzerUtil
, public virtual PDGenHandler
, public virtual PDMuonVar
, public virtual PDSoftMuonMvaEstimator
, public virtual AlbertoUtil
{
public:
PDAnalyzer();
virtual ~PDAnalyzer();
// function called before starting the analysis
virtual void beginJob();
// functions to book the histograms
void book();
// functions called for each event
// function to reset class content before reading from file
virtual void reset();
// function to do event-by-event analysis,
// return value "true" for accepted events
virtual bool analyze( int entry, int event_file, int event_tot );
// function called at the end of the analysis
virtual void endJob();
// functions called at the end of the event loop
// to plot some histogram immediately after the ntuple loop
// "uncomment" the following line
// virtual void plot(); // plot the histograms on the screen
virtual void save(); // save the histograms on a ROOT file
protected:
double ptCut; //needed for paolo's code for unknow reasons
bool verbose;
TString outputFile;
float minPtMuon, maxEtaMuon;
TString process;
int nselMu;
int nReal;
int nFake;
int nB;
int *counter;
// additional features: second ntuple
PDSecondNtupleWriter* tWriter; // second ntuple
private:
// dummy copy constructor and assignment
PDAnalyzer ( const PDAnalyzer& );
PDAnalyzer& operator=( const PDAnalyzer& );
};
#endif