27 {
edm::LogError(
"ElectronValidator::prepareStore")<<
"No DQMStore found !" ; }
37 (
const std::string &
name,
const std::string &
title,
38 int nchX,
double lowX,
double highX,
39 const std::string & titleX,
const std::string & titleY )
42 if (titleX!=
"") { me->
getTH1F()->GetXaxis()->SetTitle(titleX.c_str()) ; }
43 if (titleY!=
"") { me->
getTH1F()->GetYaxis()->SetTitle(titleY.c_str()) ; }
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 )
54 if (titleX!=
"") { me->
getTH1F()->GetXaxis()->SetTitle(titleX.c_str()) ; }
55 if (titleY!=
"") { me->
getTH1F()->GetYaxis()->SetTitle(titleY.c_str()) ; }
60 (
const std::string & name,
const std::string & title,
61 int nchX,
double lowX,
double highX,
62 int nchY,
double lowY,
double highY,
63 const std::string & titleX,
const std::string & titleY )
65 MonitorElement * me = store_->book2D(name,title,nchX,lowX,highX,nchY,lowY,highY) ;
66 if (titleX!=
"") { me->
getTH2F()->GetXaxis()->SetTitle(titleX.c_str()) ; }
67 if (titleY!=
"") { me->
getTH2F()->GetYaxis()->SetTitle(titleY.c_str()) ; }
72 (
const std::string & name,
const std::string & title,
73 int nchX,
double lowX,
double highX,
74 int nchY,
double lowY,
double highY,
75 const std::string & titleX,
const std::string & titleY )
77 MonitorElement * me = store_->book2D(name,title,nchX,lowX,highX,nchY,lowY,highY) ;
79 if (titleX!=
"") { me->
getTH2F()->GetXaxis()->SetTitle(titleX.c_str()) ; }
80 if (titleY!=
"") { me->
getTH2F()->GetYaxis()->SetTitle(titleY.c_str()) ; }
85 (
const std::string & name,
const std::string & title,
86 int nchX,
double lowX,
double highX,
87 double lowY,
double highY,
88 const std::string & titleX,
const std::string & titleY )
90 MonitorElement * me = store_->bookProfile(name,title,nchX,lowX,highX,lowY,highY) ;
91 if (titleX!=
"") { me->
getTProfile()->GetXaxis()->SetTitle(titleX.c_str()) ; }
92 if (titleY!=
"") { me->
getTProfile()->GetYaxis()->SetTitle(titleY.c_str()) ; }
98 const std::string & titleX,
const std::string & titleY,
99 const std::string & title,
bool print )
101 TH1F * h_temp = (TH1F *)num->
getTH1F()->Clone(name.c_str()) ;
104 h_temp->GetXaxis()->SetTitle(titleX.c_str()) ;
105 h_temp->GetYaxis()->SetTitle(titleY.c_str()) ;
106 if (title!=
"") { h_temp->SetTitle(title.c_str()) ; }
107 if (print) { h_temp->Print() ; }
115 const std::string & titleX,
const std::string & titleY,
116 const std::string & title,
bool print )
118 TH2F * h_temp = (TH2F *)num->
getTH2F()->Clone(name.c_str()) ;
121 h_temp->GetXaxis()->SetTitle(titleX.c_str()) ;
122 h_temp->GetYaxis()->SetTitle(titleY.c_str()) ;
123 if (title!=
"") { h_temp->SetTitle(title.c_str()) ; }
124 if (print) { h_temp->Print() ; }
132 const std::string & title,
const std::string & titleX,
const std::string & titleY,
133 Double_t minimum, Double_t maximum )
136 TProfile * p1_temp = me2d->
getTH2F()->ProfileX() ;
137 if (title!=
"") { p1_temp->SetTitle(title.c_str()) ; }
138 if (titleX!=
"") { p1_temp->GetXaxis()->SetTitle(titleX.c_str()) ; }
139 if (titleY!=
"") { p1_temp->GetYaxis()->SetTitle(titleY.c_str()) ; }
140 if (minimum!=-1111) { p1_temp->SetMinimum(minimum) ; }
141 if (maximum!=-1111) { p1_temp->SetMaximum(maximum) ; }
149 const std::string & title,
const std::string & titleX,
const std::string & titleY,
150 Double_t minimum, Double_t maximum )
153 TProfile * p1_temp = me2d->
getTH2F()->ProfileY() ;
154 if (title!=
"") { p1_temp->SetTitle(title.c_str()) ; }
155 if (titleX!=
"") { p1_temp->GetXaxis()->SetTitle(titleX.c_str()) ; }
156 if (titleY!=
"") { p1_temp->GetYaxis()->SetTitle(titleY.c_str()) ; }
157 if (minimum!=-1111) { p1_temp->SetMinimum(minimum) ; }
158 if (maximum!=-1111) { p1_temp->SetMaximum(maximum) ; }
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")
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="")
std::string print(const Track &, edm::Verbosity=edm::Concise)
Track print utility.
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")
MonitorElement * profileX(const std::string &name, MonitorElement *me2d, const std::string &title="", const std::string &titleX="", const std::string &titleY="", Double_t minimum=-1111, Double_t maximum=-1111)
void saveStore(const std::string &filename)
MonitorElement * profileY(const std::string &name, MonitorElement *me2d, const std::string &title="", const std::string &titleX="", const std::string &titleY="", Double_t minimum=-1111, Double_t maximum=-1111)
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="")
TH1F * getTH1F(void) const
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")
void setStoreFolder(const std::string &path)
TProfile * getTProfile(void) const
MonitorElement * bookH1andDivide(const std::string &name, MonitorElement *num, MonitorElement *denom, const std::string &titleX, const std::string &titleY, const std::string &title="", bool print=false)
MonitorElement * bookH2andDivide(const std::string &name, MonitorElement *num, MonitorElement *denom, const std::string &titleX, const std::string &titleY, const std::string &title="", bool print=false)
ElectronValidator(const edm::ParameterSet &conf)
TH2F * getTH2F(void) const
virtual ~ElectronValidator()
void setCurrentFolder(const std::string &fullpath)
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="")