CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
PhotonOfflineClient.cc
Go to the documentation of this file.
1 #include <iostream>
2 //
3 
5 
6 
7 //#define TWOPI 6.283185308
8 //
9 
23 using namespace std;
24 using std::cout;
25 
27 {
28 
29  dbe_ = 0;
31  dbe_->setVerbose(0);
32  parameters_ = pset;
33 
34  cutStep_ = pset.getParameter<double>("cutStep");
35  numberOfSteps_ = pset.getParameter<int>("numberOfSteps");
36 
37  etMin = pset.getParameter<double>("etMin");
38  etMax = pset.getParameter<double>("etMax");
39  etBin = pset.getParameter<int>("etBin");
40  etaMin = pset.getParameter<double>("etaMin");
41  etaMax = pset.getParameter<double>("etaMax");
42  etaBin = pset.getParameter<int>("etaBin");
43  phiMin = pset.getParameter<double>("phiMin");
44  phiMax = pset.getParameter<double>("phiMax");
45  phiBin = pset.getParameter<int>("phiBin");
46 
47  standAlone_ = pset.getParameter<bool>("standAlone");
48  batch_ = pset.getParameter<bool>("batch");
49  excludeBkgHistos_ = pset.getParameter<bool>("excludeBkgHistos");
50 
51  outputFileName_ = pset.getParameter<string>("OutputFileName");
52  inputFileName_ = pset.getUntrackedParameter<string>("InputFileName");
53 
54  histo_index_photons_ = 0;
55  histo_index_conversions_ = 0;
56  histo_index_efficiency_ = 0;
57  histo_index_invMass_ = 0;
58 
59  types_.push_back("All");
60  types_.push_back("GoodCandidate");
61  if (!excludeBkgHistos_) types_.push_back("Background");
62 
63  parts_.push_back("AllEcal");
64  parts_.push_back("Barrel");
65  parts_.push_back("Endcaps");
66 
67 }
68 
70 {}
72 {}
74 {}
76 {}
77 
78 
79 
81 {
82  if(standAlone_) runClient();
83 }
85 {
86  if(!standAlone_) runClient();
87 }
88 
89 
90 
91 
93 {
94  if(!dbe_) return;
95 
96  if(batch_) dbe_->open(inputFileName_);
97 
98  if(!dbe_->dirExists("Egamma/PhotonAnalyzer")){
99  //cout << "egamma directory doesn't exist..." << std::endl;
100  return;
101  }
102 
103  //find out how many histograms are in the various folders
104  histo_index_photons_ = dbe_->get("Egamma/PhotonAnalyzer/numberOfHistogramsInPhotonsFolder")->getIntValue();
105  histo_index_conversions_ = dbe_->get("Egamma/PhotonAnalyzer/numberOfHistogramsInConversionsFolder")->getIntValue();
106  histo_index_efficiency_ = dbe_->get("Egamma/PhotonAnalyzer/numberOfHistogramsInEfficiencyFolder")->getIntValue();
107  histo_index_invMass_ = dbe_->get("Egamma/PhotonAnalyzer/numberOfHistogramsInInvMassFolder")->getIntValue();
108 
109  dbe_->setCurrentFolder("Egamma/PhotonAnalyzer/");
110  dbe_->removeElement("numberOfHistogramsInPhotonsFolder");
111  dbe_->removeElement("numberOfHistogramsInConversionsFolder");
112  dbe_->removeElement("numberOfHistogramsInEfficiencyFolder");
113  dbe_->removeElement("numberOfHistogramsInInvMassFolder");
114 
115 
116  string AllPath = "Egamma/PhotonAnalyzer/AllPhotons/";
117  string IsoPath = "Egamma/PhotonAnalyzer/GoodCandidatePhotons/";
118  string NonisoPath = "Egamma/PhotonAnalyzer/BackgroundPhotons/";
119  string EffPath = "Egamma/PhotonAnalyzer/Efficiencies/";
120 
121 
122  //booking efficiency histograms
123  dbe_->setCurrentFolder(EffPath);
124 
125  p_efficiencyVsEtaLoose_ = bookHisto("EfficiencyVsEtaLoose","Fraction of Photons passing Loose Isolation vs #eta;#eta",etaBin,etaMin, etaMax);
126  p_efficiencyVsEtLoose_ = bookHisto("EfficiencyVsEtLoose", "Fraction of Photons passing Loose Isolation vs E_{T};E_{T} (GeV)",etBin,etMin,etMax);
127  p_efficiencyVsEtaTight_ = bookHisto("EfficiencyVsEtaTight","Fraction of Photons passing Tight Isolation vs #eta;#eta",etaBin,etaMin, etaMax);
128  p_efficiencyVsEtTight_ = bookHisto("EfficiencyVsEtTight", "Fraction of Photons passing Tight Isolation vs E_{T};E_{T} (GeV)",etBin,etMin,etMax);
129 
130 
131  p_efficiencyVsEtaHLT_ = bookHisto("EfficiencyVsEtaHLT","Fraction of Photons firing HLT vs #eta;#eta",etaBin,etaMin, etaMax);
132  p_efficiencyVsEtHLT_ = bookHisto("EfficiencyVsEtHLT", "Fraction of Photons firing HLT vs E_{T};E_{T} (GeV)",etBin,etMin,etMax);
133 
134 
135  p_convFractionVsEtaLoose_ = bookHisto("ConvFractionVsEtaLoose","Fraction of Loosely Isolated Photons which are matched to two tracks vs #eta;#eta",etaBin,etaMin, etaMax);
136  p_convFractionVsEtLoose_ = bookHisto("ConvFractionVsEtLoose", "Fraction of Loosely Isolated Photons which are matched to two tracks vs E_{T};E_{T} (GeV)",etBin,etMin,etMax);
137  p_convFractionVsEtaTight_ = bookHisto("ConvFractionVsEtaTight","Fraction of Tightly Isolated Photons which are matched to two tracks vs #eta;#eta",etaBin,etaMin, etaMax);
138  p_convFractionVsEtTight_ = bookHisto("ConvFractionVsEtTight", "Fraction of Tightly Isolated Photons which are matched to two tracks vs E_{T};E_{T} (GeV)",etBin,etMin,etMax);
139 
140  p_vertexReconstructionEfficiencyVsEta_ = bookHisto("VertexReconstructionEfficiencyVsEta","Fraction of Converted Photons which have a valid vertex vs #eta;#eta",etaBin,etaMin, etaMax);
141 
142 
143  //booking conversion fraction histograms
144  dbe_->setCurrentFolder(AllPath+"Et above 20 GeV/Conversions");
145  p_convFractionVsEt_ = book2DHistoVector("1D","convFractionVsEt", "Fraction of Converted Photons vs E_{T};E_{T} (GeV)",etBin,etMin,etMax);
146  p_convFractionVsPhi_ = book3DHistoVector("1D","convFractionVsPhi","Fraction of Converted Photons vs #phi;#phi",phiBin,phiMin,phiMax);
147  p_convFractionVsEta_ = book2DHistoVector("1D","convFractionVsEta","Fraction of Converted Photons vs #eta;#eta",etaBin,etaMin,etaMax);
148 
149 
150  //booking bad channel fraction histograms
151  dbe_->setCurrentFolder(AllPath+"Et above 20 GeV/");
152  p_badChannelsFractionVsPhi_ = book2DHistoVector("1D","badChannelsFractionVsPhi","Fraction of Photons which have at least one bad channel vs #phi;#phi",phiBin,phiMin,phiMax);
153  p_badChannelsFractionVsEta_ = book2DHistoVector("1D","badChannelsFractionVsEta","Fraction of Photons which have at least one bad channel vs #eta;#eta",etaBin,etaMin, etaMax);
154  p_badChannelsFractionVsEt_ = book2DHistoVector("1D","badChannelsFractionVsEt", "Fraction of Photons which have at least one bad channel vs E_{T};E_{T} (GeV)",etBin,etMin,etMax);
155 
156 
157 
158  //making efficiency plots
159 
160  MonitorElement * dividend;
161  MonitorElement * numerator;
163 
164  currentFolder_.str("");
165  currentFolder_ << AllPath << "Et above 20 GeV/";
166 
167  //HLT efficiency plots
168  dividend = retrieveHisto(EffPath,"EfficiencyVsEtaHLT");
169  numerator = retrieveHisto(EffPath,"phoEtaPostHLT");
170  denominator = retrieveHisto(EffPath,"phoEtaPreHLT");
171  dividePlots(dividend,numerator,denominator);
172 
173  dividend = retrieveHisto(EffPath,"EfficiencyVsEtHLT");
174  numerator = retrieveHisto(EffPath,"phoEtPostHLT");
175  denominator = retrieveHisto(EffPath,"phoEtPreHLT");
176  dividePlots(dividend,numerator,denominator);
177 
178 
179  //efficiencies vs Eta
180  denominator = retrieveHisto(currentFolder_.str(),"phoEta");
181 
182  dividend = retrieveHisto(EffPath,"EfficiencyVsEtaLoose");
183  numerator = retrieveHisto(EffPath,"phoEtaLoose");
184  dividePlots(dividend,numerator,denominator);
185 
186  dividend = retrieveHisto(EffPath,"EfficiencyVsEtaTight");
187  numerator = retrieveHisto(EffPath,"phoEtaTight");
188  dividePlots(dividend,numerator,denominator);
189 
190 
191  //efficiencies vs Et
192  denominator = retrieveHisto(currentFolder_.str(),"phoEtAllEcal");
193 
194  dividend = retrieveHisto(EffPath,"EfficiencyVsEtLoose");
195  numerator = retrieveHisto(EffPath,"phoEtLoose");
196  dividePlots(dividend,numerator,denominator);
197 
198  dividend = retrieveHisto(EffPath,"EfficiencyVsEtTight");
199  numerator = retrieveHisto(EffPath,"phoEtTight");
200  dividePlots(dividend,numerator,denominator);
201 
202 
203  //conversion fractions vs Eta
204  dividend = retrieveHisto(EffPath,"ConvFractionVsEtaLoose");
205  numerator = retrieveHisto(EffPath,"convEtaLoose");
206  denominator = retrieveHisto(EffPath,"phoEtaLoose");
207  dividePlots(dividend,numerator,denominator);
208 
209  dividend = retrieveHisto(EffPath,"ConvFractionVsEtaTight");
210  numerator = retrieveHisto(EffPath,"convEtaTight");
211  denominator = retrieveHisto(EffPath,"phoEtaTight");
212  dividePlots(dividend,numerator,denominator);
213 
214 
215  //conversion fractions vs Et
216  dividend = retrieveHisto(EffPath,"ConvFractionVsEtLoose");
217  numerator = retrieveHisto(EffPath,"convEtLoose");
218  denominator = retrieveHisto(EffPath,"phoEtLoose");
219  dividePlots(dividend,numerator,denominator);
220 
221  dividend = retrieveHisto(EffPath,"ConvFractionVsEtTight");
222  numerator = retrieveHisto(EffPath,"convEtTight");
223  denominator = retrieveHisto(EffPath,"phoEtTight");
224  dividePlots(dividend,numerator,denominator);
225 
226 
227  //conversion vertex recontruction efficiency
228  dividend = retrieveHisto(EffPath,"VertexReconstructionEfficiencyVsEta");
229  numerator = retrieveHisto(currentFolder_.str()+"Conversions/","phoConvEta");
230  denominator = retrieveHisto(EffPath,"phoEtaVertex");
231  dividePlots(dividend,numerator,denominator);
232 
233 
234  dbe_->setCurrentFolder(EffPath);
235 
236 
237  dbe_->removeElement("phoEtaPreHLT");
238  dbe_->removeElement("phoEtPreHLT");
239  dbe_->removeElement("phoEtaPostHLT");
240  dbe_->removeElement("phoEtPostHLT");
241  dbe_->removeElement("phoEtaLoose");
242  dbe_->removeElement("phoEtaTight");
243  dbe_->removeElement("phoEtLoose");
244  dbe_->removeElement("phoEtTight");
245  dbe_->removeElement("phoEtaVertex");
246  dbe_->removeElement("convEtaLoose");
247  dbe_->removeElement("convEtaTight");
248  dbe_->removeElement("convEtLoose");
249  dbe_->removeElement("convEtTight");
250 
251 
252  for(uint type=0;type!=types_.size();++type){
253 
254  for (int cut = 0; cut !=numberOfSteps_; ++cut) {
255 
256  currentFolder_.str("");
257  currentFolder_ << "Egamma/PhotonAnalyzer/" << types_[type] << "Photons/Et above " << (cut+1)*cutStep_ << " GeV/";
258 
259  //making bad channel histograms
260 
261  //vs Et
262  dividend = retrieveHisto(currentFolder_.str(),"badChannelsFractionVsEt");
263  numerator = retrieveHisto(currentFolder_.str(),"phoEtBadChannels");
264  denominator = retrieveHisto(currentFolder_.str(),"phoEtAllEcal");
265  dividePlots(dividend,numerator,denominator);
266 
267  //vs eta
268  dividend = retrieveHisto(currentFolder_.str(),"badChannelsFractionVsEta");
269  numerator = retrieveHisto(currentFolder_.str(),"phoEtaBadChannels");
270  denominator = retrieveHisto(currentFolder_.str(),"phoEta");
271  dividePlots(dividend,numerator,denominator);
272 
273  //vs phi
274  dividend = retrieveHisto(currentFolder_.str(),"badChannelsFractionVsPhi");
275  numerator = retrieveHisto(currentFolder_.str(),"phoPhiBadChannels");
276  denominator = retrieveHisto(currentFolder_.str(),"phoPhiAllEcal");
277  dividePlots(dividend,numerator,denominator);
278 
279  //making conversion fraction histograms
280 
281  //vs Et
282  dividend = retrieveHisto(currentFolder_.str()+"Conversions/","convFractionVsEt");
283  numerator = retrieveHisto(currentFolder_.str()+"Conversions/","phoConvEtAllEcal");
284  denominator = retrieveHisto(currentFolder_.str(),"phoEtAllEcal");
285  dividePlots(dividend,numerator,denominator);
286 
287  //vs eta
288  dividend = retrieveHisto(currentFolder_.str()+"Conversions/","convFractionVsEta");
289  numerator = retrieveHisto(currentFolder_.str()+"Conversions/","phoConvEtaForEfficiency");
290  denominator = retrieveHisto(currentFolder_.str(),"phoEta");
291  dividePlots(dividend,numerator,denominator);
292 
293  //vs phi
294  dividend = retrieveHisto(currentFolder_.str()+"Conversions/","convFractionVsPhiAllEcal");
295  numerator = retrieveHisto(currentFolder_.str()+"Conversions/","phoConvPhiForEfficiencyAllEcal");
296  denominator = retrieveHisto(currentFolder_.str(),"phoPhiAllEcal");
297  dividePlots(dividend,numerator,denominator);
298  dividend = retrieveHisto(currentFolder_.str()+"Conversions/","convFractionVsPhiBarrel");
299  numerator = retrieveHisto(currentFolder_.str()+"Conversions/","phoConvPhiForEfficiencyBarrel");
300  denominator = retrieveHisto(currentFolder_.str(),"phoPhiBarrel");
301  dividePlots(dividend,numerator,denominator);
302  dividend = retrieveHisto(currentFolder_.str()+"Conversions/","convFractionVsPhiEndcaps");
303  numerator = retrieveHisto(currentFolder_.str()+"Conversions/","phoConvPhiForEfficiencyEndcaps");
304  denominator = retrieveHisto(currentFolder_.str(),"phoPhiEndcaps");
305  dividePlots(dividend,numerator,denominator);
306 
307 
308  dbe_->setCurrentFolder(currentFolder_.str()+"Conversions/");
309  dbe_->removeElement("phoConvEtaForEfficiency");
310  dbe_->removeElement("phoConvPhiForEfficiencyAllEcal");
311  dbe_->removeElement("phoConvPhiForEfficiencyBarrel");
312  dbe_->removeElement("phoConvPhiForEfficiencyEndcaps");
313 
314  }
315 
316 
317  }
318 
319 
320  if(standAlone_) dbe_->save(outputFileName_);
321  else if(batch_) dbe_->save(inputFileName_);
322 
323 
324 }
325 
326 
327 
328 
330  double value,err;
331 
332  if(denominator->getEntries()==0) return;
333 
334  for (int j=1; j<=numerator->getNbinsX(); j++){
335  if (denominator->getBinContent(j)!=0){
336  value = ((double) numerator->getBinContent(j))/((double) denominator->getBinContent(j));
337  err = sqrt( value*(1-value) / ((double) denominator->getBinContent(j)) );
338  dividend->setBinContent(j, value);
339  dividend->setBinError(j,err);
340  }
341  else {
342  dividend->setBinContent(j, 0);
343  dividend->setBinError(j,0);
344  }
345  dividend->setEntries(numerator->getEntries());
346  }
347 }
348 
349 
351  double value,err;
352 
353  for (int j=1; j<=numerator->getNbinsX(); j++){
354  if (denominator!=0){
355  value = ((double) numerator->getBinContent(j))/denominator;
356  err = sqrt( value*(1-value) / denominator);
357  dividend->setBinContent(j, value);
358  dividend->setBinError(j,err);
359  }
360  else {
361  dividend->setBinContent(j, 0);
362  }
363  }
364 
365 }
366 
367 MonitorElement* PhotonOfflineClient::bookHisto(string histoName, string title, int bin, double min, double max)
368 {
369 
370  int histo_index = 0;
371  stringstream histo_number_stream;
372 
373 
374  //determining which folder we're in
375  if(dbe_->pwd().find( "InvMass" ) != string::npos){
376  histo_index_invMass_++;
377  histo_index = histo_index_invMass_;
378  }
379  if(dbe_->pwd().find( "Efficiencies" ) != string::npos){
380  histo_index_efficiency_++;
381  histo_index = histo_index_efficiency_;
382  }
383  histo_number_stream << "h_";
384  if(histo_index<10) histo_number_stream << "0";
385  histo_number_stream << histo_index;
386 
387  return dbe_->book1D(histo_number_stream.str()+"_"+histoName,title,bin,min,max);
388 
389 }
390 
391 vector<vector<MonitorElement*> > PhotonOfflineClient::book2DHistoVector(string histoType, string histoName, string title,
392  int xbin, double xmin,double xmax,
393  int ybin, double ymin, double ymax)
394 {
395  int histo_index = 0;
396 
397  vector<MonitorElement*> temp1DVector;
398  vector<vector<MonitorElement*> > temp2DVector;
399 
400  //determining which folder we're in
401  bool conversionPlot = false;
402  if(dbe_->pwd().find( "Conversions" ) != string::npos) conversionPlot = true;
403 
404 
405  if(conversionPlot){
406  histo_index_conversions_++;
407  histo_index = histo_index_conversions_;
408  }
409  else{
410  histo_index_photons_++;
411  histo_index = histo_index_photons_;
412  }
413 
414 
415  stringstream histo_number_stream;
416  histo_number_stream << "h_";
417  if(histo_index<10) histo_number_stream << "0";
418  histo_number_stream << histo_index << "_";
419 
420 
421  for(int cut = 0; cut != numberOfSteps_; ++cut){ //looping over Et cut values
422 
423  for(uint type=0;type!=types_.size();++type){ //looping over isolation type
424 
425  currentFolder_.str("");
426  currentFolder_ << "Egamma/PhotonAnalyzer/" << types_[type] << "Photons/Et above " << (cut+1)*cutStep_ << " GeV";
427  if(conversionPlot) currentFolder_ << "/Conversions";
428 
429  dbe_->setCurrentFolder(currentFolder_.str());
430 
431  string kind;
432  if(conversionPlot) kind = " Conversions: ";
433  else kind = " Photons: ";
434 
435  if(histoType=="1D") temp1DVector.push_back(dbe_->book1D(histo_number_stream.str()+histoName,types_[type]+kind+title,xbin,xmin,xmax));
436  else if(histoType=="2D") temp1DVector.push_back(dbe_->book2D(histo_number_stream.str()+histoName,types_[type]+kind+title,xbin,xmin,xmax,ybin,ymin,ymax));
437  else if(histoType=="Profile") temp1DVector.push_back(dbe_->bookProfile(histo_number_stream.str()+histoName,types_[type]+kind+title,xbin,xmin,xmax,ybin,ymin,ymax,""));
438  //else cout << "bad histoType\n";
439  }
440 
441  temp2DVector.push_back(temp1DVector);
442  temp1DVector.clear();
443  }
444 
445  return temp2DVector;
446 
447 }
448 
449 
450 
451 vector<vector<vector<MonitorElement*> > > PhotonOfflineClient::book3DHistoVector(string histoType, string histoName, string title,
452  int xbin, double xmin,double xmax,
453  int ybin, double ymin, double ymax)
454 {
455  int histo_index = 0;
456 
457  vector<MonitorElement*> temp1DVector;
458  vector<vector<MonitorElement*> > temp2DVector;
459  vector<vector<vector<MonitorElement*> > > temp3DVector;
460 
461 
462  //determining which folder we're in
463  bool conversionPlot = false;
464  if(dbe_->pwd().find( "Conversions" ) != string::npos) conversionPlot = true;
465 
466 
467  if(conversionPlot){
468  histo_index_conversions_++;
469  histo_index = histo_index_conversions_;
470  }
471  else{
472  histo_index_photons_++;
473  histo_index = histo_index_photons_;
474  }
475 
476  stringstream histo_number_stream;
477  histo_number_stream << "h_";
478  if(histo_index<10) histo_number_stream << "0";
479  histo_number_stream << histo_index << "_";
480 
481 
482  for(int cut = 0; cut != numberOfSteps_; ++cut){ //looping over Et cut values
483 
484  for(uint type=0;type!=types_.size();++type){ //looping over isolation type
485 
486  for(uint part=0;part!=parts_.size();++part){ //looping over different parts of the ecal
487 
488  currentFolder_.str("");
489  currentFolder_ << "Egamma/PhotonAnalyzer/" << types_[type] << "Photons/Et above " << (cut+1)*cutStep_ << " GeV";
490  if(conversionPlot) currentFolder_ << "/Conversions";
491 
492  dbe_->setCurrentFolder(currentFolder_.str());
493 
494  string kind;
495  if(conversionPlot) kind = " Conversions: ";
496  else kind = " Photons: ";
497 
498  if(histoType=="1D") temp1DVector.push_back(dbe_->book1D( histo_number_stream.str()+histoName+parts_[part],types_[type]+kind+parts_[part]+": "+title,xbin,xmin,xmax));
499  else if(histoType=="2D") temp1DVector.push_back(dbe_->book2D( histo_number_stream.str()+histoName+parts_[part],types_[type]+kind+parts_[part]+": "+title,xbin,xmin,xmax,ybin,ymin,ymax));
500  else if(histoType=="Profile") temp1DVector.push_back(dbe_->bookProfile( histo_number_stream.str()+histoName+parts_[part],types_[type]+kind+parts_[part]+": "+title,xbin,xmin,xmax,ybin,ymin,ymax,""));
501  //else cout << "bad histoType\n";
502 
503 
504  }
505 
506  temp2DVector.push_back(temp1DVector);
507  temp1DVector.clear();
508  }
509 
510  temp3DVector.push_back(temp2DVector);
511  temp2DVector.clear();
512  }
513 
514  return temp3DVector;
515 }
516 
517 
519  //cout << "dir = " << dir << endl;
520  //cout << "name = " << name << endl;
521  vector<MonitorElement*> histoVector;
522  uint indexOfRelevantHistogram=0;
523  string fullMEName = "";
524  histoVector = dbe_->getContents(dir);
525  for(uint index=0;index!=histoVector.size();index++){
526  string MEName = histoVector[index]->getName();
527  if(MEName.find( name ) != string::npos){
528  indexOfRelevantHistogram = index;
529  break;
530  }
531  }
532  return histoVector[indexOfRelevantHistogram];
533 }
534 
type
Definition: HCALResponse.h:22
T getParameter(std::string const &) const
T getUntrackedParameter(std::string const &, T const &) const
void setBinContent(int binx, double content)
set content of bin (1-D)
MonitorElement * book1D(const char *name, const char *title, int nchX, double lowX, double highX)
Book 1D histogram.
Definition: DQMStore.cc:717
virtual void analyze(const edm::Event &, const edm::EventSetup &)
void save(const std::string &filename, const std::string &path="", const std::string &pattern="", const std::string &rewrite="", SaveReferenceTag ref=SaveWithReference, int minStatus=dqm::qstatus::STATUS_OK, const std::string &fileupdate="RECREATE")
Definition: DQMStore.cc:2113
PhotonOfflineClient(const edm::ParameterSet &pset)
#define min(a, b)
Definition: mlp_lapack.h:161
double getEntries(void) const
get # of entries
virtual void endRun(const edm::Run &, const edm::EventSetup &)
std::vector< std::vector< std::vector< MonitorElement * > > > book3DHistoVector(std::string histoType, std::string histoName, std::string title, int xbin, double xmin, double xmax, int ybin=1, double ymin=1, double ymax=2)
std::vector< std::vector< MonitorElement * > > book2DHistoVector(std::string histoType, std::string histoName, std::string title, int xbin, double xmin, double xmax, int ybin=1, double ymin=1, double ymax=2)
const T & max(const T &a, const T &b)
T sqrt(T t)
Definition: SSEVec.h:46
void removeElement(const std::string &name)
Definition: DQMStore.cc:2572
void dividePlots(MonitorElement *dividend, MonitorElement *numerator, MonitorElement *denominator)
int j
Definition: DBlmapReader.cc:9
void setBinError(int binx, double error)
set uncertainty on content of bin (1-D)
MonitorElement * bookProfile(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, const char *option="s")
Definition: DQMStore.cc:1031
void setVerbose(unsigned level)
Definition: DQMStore.cc:393
void setEntries(double nentries)
set # of entries
MonitorElement * get(const std::string &path) const
get ME from full pathname (e.g. &quot;my/long/dir/my_histo&quot;)
Definition: DQMStore.cc:1468
std::vector< MonitorElement * > getContents(const std::string &path) const
Definition: DQMStore.cc:1497
DQMStore * dbe_
bool etMin(const PFCandidate &cand, double cut)
bool dirExists(const std::string &path) const
true if directory exists
Definition: DQMStore.cc:493
MonitorElement * retrieveHisto(std::string dir, std::string name)
MonitorElement * bookHisto(std::string histoName, std::string title, int bin, double min, double max)
part
Definition: HCALResponse.h:21
int64_t getIntValue(void) const
double getBinContent(int binx) const
get content of bin (1-D)
virtual void endLuminosityBlock(const edm::LuminosityBlock &, const edm::EventSetup &)
int getNbinsX(void) const
get # of bins in X-axis
bool open(const std::string &filename, bool overwrite=false, const std::string &path="", const std::string &prepend="", OpenRunDirs stripdirs=KeepRunDirs, bool fileMustExist=true)
Definition: DQMStore.cc:2432
tuple cout
Definition: gather_cfg.py:121
dbl *** dir
Definition: mlp_gen.cc:35
MonitorElement * book2D(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY)
Book 2D histogram.
Definition: DQMStore.cc:845
void setup(std::vector< TH2F > &depth, std::string name, std::string units="")
void setCurrentFolder(const std::string &fullpath)
Definition: DQMStore.cc:429
Definition: Run.h:33
const std::string & pwd(void) const
Definition: DQMStore.cc:401