CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
DTResolutionAnalysisTest.h
Go to the documentation of this file.
1 #ifndef DTResolutionAnalysisTest_H
2 #define DTResolutionAnalysisTest_H
3 
4 
16 
19 
20 #include <string>
21 #include <map>
22 
23 class DTGeometry;
24 class DTSuperLayerId;
25 class DQMStore;
26 class MonitorElement;
27 
28 
30 
31 public:
32 
35 
37  virtual ~DTResolutionAnalysisTest();
38 
40  void beginJob();
41 
43  void beginRun(const edm::Run& r, const edm::EventSetup& c);
44 
46  void analyze(const edm::Event& e, const edm::EventSetup& c);
47 
49  void bookHistos();
50  void bookHistos(int wh);
51  void bookHistos(int wh, int sect);
52 
54  std::string getMEName(const DTSuperLayerId & slID);
55 
56  void beginLuminosityBlock(edm::LuminosityBlock const& lumiSeg, edm::EventSetup const& context) ;
57 
59  void endLuminosityBlock(edm::LuminosityBlock const& lumiSeg, edm::EventSetup const& c);
60  void endRun(edm::Run const& run, edm::EventSetup const& c);
61 
62 
63 
64 private:
65  void resetMEs();
66 
67  int nevents;
68  unsigned int nLumiSegs;
70  int run;
72 
74 
75  // permitted test ranges
80 
82 
84 
85  // Histograms for tests
86  std::map< std::pair<int,int> , MonitorElement* > MeanHistos;
87  std::map< std::pair<int,int> , MonitorElement* > SigmaHistos;
88  // wheel summary histograms
89  std::map< int, MonitorElement* > wheelMeanHistos;
90  std::map< int, MonitorElement* > wheelSigmaHistos;
91 
92  std::map< int, MonitorElement* > meanDistr;
93  std::map< int, MonitorElement* > sigmaDistr;
94 
95 
96  // Compute the station from the bin number of mean and sigma histos
97  int stationFromBin(int bin) const;
98  // Compute the sl from the bin number of mean and sigma histos
99  int slFromBin(int bin) const;
100 
101  double meanInRange(double mean) const;
102  double sigmaInRange(double sigma) const;
103 
105 
106  // top folder for the histograms in DQMStore
108 
109 };
110 
111 #endif
std::map< std::pair< int, int >, MonitorElement * > SigmaHistos
double meanInRange(double mean) const
std::map< int, MonitorElement * > sigmaDistr
DTResolutionAnalysisTest(const edm::ParameterSet &ps)
Constructor.
void endLuminosityBlock(edm::LuminosityBlock const &lumiSeg, edm::EventSetup const &c)
DQM Client Diagnostic.
void beginLuminosityBlock(edm::LuminosityBlock const &lumiSeg, edm::EventSetup const &context)
std::string getMEName(const DTSuperLayerId &slID)
Get the ME name.
virtual ~DTResolutionAnalysisTest()
Destructor.
edm::ESHandle< DTGeometry > muonGeom
std::map< std::pair< int, int >, MonitorElement * > MeanHistos
void bookHistos()
book the summary histograms
std::map< int, MonitorElement * > wheelMeanHistos
double sigmaInRange(double sigma) const
std::map< int, MonitorElement * > wheelSigmaHistos
std::map< int, MonitorElement * > meanDistr
void beginRun(const edm::Run &r, const edm::EventSetup &c)
BeginRun.
Definition: Run.h:41
void analyze(const edm::Event &e, const edm::EventSetup &c)
Analyze.
void endRun(edm::Run const &run, edm::EventSetup const &c)