CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ScoutingAnalyzerBase.h
Go to the documentation of this file.
1 #ifndef ScoutingAnalyzerBase_h
2 #define ScoutingAnalyzerBase_h
3 
4 /* This class, as this whole package, was inspired by the EGamma monitoring
5  * by David Chamont. The idea is to provide a base class for all the monitoring
6  * modules implemented as plugins.
7  * The methods of the base class will spare the developer the pain of allocating
8  * all the ME, make projections and manipulations with extremely ugly copy&paste
9  * code sections
10  * */
11 class DQMStore ;
12 class MonitorElement ;
13 
18 
19 #include <Rtypes.h>
20 
22  {
23 
24  protected:
25 
26  explicit ScoutingAnalyzerBase( const edm::ParameterSet & conf ) ;
27  virtual ~ScoutingAnalyzerBase() ;
28 
29 
30  void beginJob() ;
31  virtual void endRun( edm::Run const &, edm::EventSetup const & ){};
32  virtual void endLuminosityBlock( edm::LuminosityBlock const &, edm::EventSetup const & ) {}
33  virtual void endJob(){};
34  virtual void analyze( const edm::Event & e, const edm::EventSetup & c ) {}
35 
36  virtual void bookMEs() {}
37 
39 
40  // Members for ME booking
42  ( const std::string & name, const std::string & title,
43  int nchX, double lowX, double highX,
44  const std::string & titleX ="", const std::string & titleY ="Events",
45  Option_t * option = "E1 P" ) ;
46 
48  ( const std::string & name, const std::string & title,
49  int nchX, double lowX, double highX,
50  const std::string & titleX ="", const std::string & titleY ="Events",
51  Option_t * option = "E1 P" ) ;
52 
54  ( const std::string & name, const std::string & title,
55  int nchX, float *xbinsize,
56  const std::string & titleX ="", const std::string & titleY ="Events",
57  Option_t * option = "E1 P" ) ;
58 
60  ( const std::string & name, const std::string & title,
61  int nchX, float *xbinsize,
62  const std::string & titleX ="", const std::string & titleY ="Events",
63  Option_t * option = "E1 P" ) ;
64 
66  ( const std::string & name, const std::string & title,
67  int nchX, double lowX, double highX,
68  int nchY, double lowY, double highY,
69  const std::string & titleX ="", const std::string & titleY ="",
70  Option_t * option = "COLZ" ) ;
71 
73  ( const std::string & name, const std::string & title,
74  int nchX, double lowX, double highX,
75  int nchY, double lowY, double highY,
76  const std::string & titleX ="", const std::string & titleY ="",
77  Option_t * option = "COLZ" ) ;
78 
80  ( const std::string & name, const std::string & title,
81  int nchX, double lowX, double highX,
82  double lowY, double highY,
83  const std::string & titleX ="", const std::string & titleY ="",
84  Option_t * option = "E1 P" ) ;
85 
87  ( const std::string & name, MonitorElement * num, MonitorElement * denom,
88  const std::string & titleX, const std::string & titleY,
89  const std::string & title ="" ) ;
90 
92  ( const std::string & name, MonitorElement * num, MonitorElement * denom,
93  const std::string & titleX, const std::string & titleY,
94  const std::string & title ="" ) ;
95 
97  ( MonitorElement * me2d,
98  const std::string & title ="", const std::string & titleX ="", const std::string & titleY ="",
99  Double_t minimum = -1111, Double_t maximum = -1111 ) ;
100 
102  ( MonitorElement * me2d,
103  const std::string & title ="", const std::string & titleX ="", const std::string & titleY ="",
104  Double_t minimum = -1111, Double_t maximum = -1111 ) ;
105 
106 
107  private:
112 
113  } ;
114 
115 #endif
116 
MonitorElement * bookH2withSumw2(const std::string &name, const std::string &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, const std::string &titleX="", const std::string &titleY="", Option_t *option="COLZ")
MonitorElement * bookH1withSumw2(const std::string &name, const std::string &title, int nchX, double lowX, double highX, const std::string &titleX="", const std::string &titleY="Events", Option_t *option="E1 P")
MonitorElement * bookP1(const std::string &name, const std::string &title, int nchX, double lowX, double highX, double lowY, double highY, const std::string &titleX="", const std::string &titleY="", Option_t *option="E1 P")
MonitorElement * bookH1withSumw2BinArray(const std::string &name, const std::string &title, int nchX, float *xbinsize, const std::string &titleX="", const std::string &titleY="Events", Option_t *option="E1 P")
MonitorElement * profileY(MonitorElement *me2d, const std::string &title="", const std::string &titleX="", const std::string &titleY="", Double_t minimum=-1111, Double_t maximum=-1111)
std::string newName(const std::string &name)
MonitorElement * profileX(MonitorElement *me2d, const std::string &title="", const std::string &titleX="", const std::string &titleY="", Double_t minimum=-1111, Double_t maximum=-1111)
virtual void analyze(const edm::Event &e, const edm::EventSetup &c)
virtual void endRun(edm::Run const &, edm::EventSetup const &)
virtual void endLuminosityBlock(edm::LuminosityBlock const &, edm::EventSetup const &)
tuple conf
Definition: dbtoconf.py:185
ScoutingAnalyzerBase(const edm::ParameterSet &conf)
MonitorElement * bookH1BinArray(const std::string &name, const std::string &title, int nchX, float *xbinsize, const std::string &titleX="", const std::string &titleY="Events", Option_t *option="E1 P")
MonitorElement * bookH1(const std::string &name, const std::string &title, int nchX, double lowX, double highX, const std::string &titleX="", const std::string &titleY="Events", Option_t *option="E1 P")
MonitorElement * bookH2andDivide(const std::string &name, MonitorElement *num, MonitorElement *denom, const std::string &titleX, const std::string &titleY, const std::string &title="")
MonitorElement * bookH1andDivide(const std::string &name, MonitorElement *num, MonitorElement *denom, const std::string &titleX, const std::string &titleY, const std::string &title="")
Definition: Run.h:41
MonitorElement * bookH2(const std::string &name, const std::string &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, const std::string &titleX="", const std::string &titleY="", Option_t *option="COLZ")