109 if(!HOCalib.isValid()){
110 LogDebug(
"") <<
"DQMHOAlCaRecoStream:: Error! can't get HOCalib product!" << std::endl;
116 hMuonMultipl->Fill((*HOCalib).size(),1.);
117 if ((*HOCalib).size() >0 ) {
118 for (HOCalibVariableCollection::const_iterator hoC=(*HOCalib).begin(); hoC!=(*HOCalib).end(); hoC++){
124 if (dr <m_lowRadPosInMuch || dr >m_highRadPosInMuch)
continue;
126 if ((*hoC).isect <0)
continue;
127 if (fabs((*hoC).trkth-acos(-1.)/2)<0.000001)
continue;
128 int ieta = int((
std::abs((*hoC).isect)%10000)/100.)-30;
135 hMuonMom->Fill((*hoC).trkmm, 1.0);
136 hMuonEta->Fill(-
log(
tan((*hoC).trkth/2.0)), 1.0);
137 hMuonPhi->Fill((*hoC).trkph, 1.0);
138 hDirCosine->Fill((*hoC).hoang, 1.0);
139 hHOTime->Fill((*hoC).htime, 1.0);
141 double energy = (*hoC).hosig[4];
142 double pedval = (*hoC).hocro;
144 if (ieta >=-15 && ieta <=-11) {iring = -2;}
145 else if (ieta >=-10 && ieta <=-5) {iring = -1;}
146 else if (ieta >= 5 && ieta <= 10) {iring = 1;}
147 else if (ieta >= 11 && ieta <= 15) {iring = 2;}
149 hSigRing[iring+2]->Fill(energy,1.0);
150 hPedRing[iring+2]->Fill(pedval,1.0);
152 for (
int k=0;
k<9;
k++) {
153 hSignal3x3[
k]->Fill((*hoC).hosig[
k]);
171 hMuonMom =
dbe_->
book1D(
"hMuonMom",
"Muon momentum (GeV)", 50, -100, 100);
174 hMuonEta =
dbe_->
book1D(
"hMuonEta",
"Pseudo-rapidity of muon", 50, -1.5, 1.5);
177 hMuonPhi =
dbe_->
book1D(
"hMuonPhi",
"Azimuthal angle of muon", 24, -acos(-1), acos(-1));
180 hMuonMultipl =
dbe_->
book1D(
"hMuonMultipl",
"Muon Multiplicity", 10, 0.5, 10.5);
183 hDirCosine =
dbe_->
book1D(
"hDirCosine",
"Direction Cosine of muon at HO tower", 50, -1., 1.);
184 hDirCosine ->
setAxisTitle(
"Direction Cosine of muon at HO tower",1);
186 hHOTime =
dbe_->
book1D(
"hHOTime",
"HO time distribution", 60, -20, 100.);
189 for (
int i=0;
i<5;
i++) {
190 sprintf(name,
"hSigRing_%i",
i-2);
191 sprintf(title,
"HO signal in Ring_%i",
i-2);
192 hSigRing[
i] =
dbe_->
book1D(name, title, m_nbins, m_lowEdge, m_highEdge);
195 sprintf(name,
"hPedRing_%i",
i-2);
196 sprintf(title,
"HO Pedestal in Ring_%i",
i-2);
197 hPedRing[
i] =
dbe_->
book1D(name, title, m_nbins, m_lowEdge, m_highEdge);
219 for (
int i=-1;
i<=1;
i++) {
220 for (
int j=-1;
j<=1;
j++) {
223 sprintf(title,
"hSignal3x3_deta%i_dphi%i",
i,
j);
224 hSignal3x3[
k] =
dbe_->
book1D(title, title, m_nbins, m_lowEdge, m_highEdge);
241 hMuonMom->getTH1F()->Scale(scale);
242 hMuonEta->getTH1F()->Scale(scale);
243 hMuonPhi->getTH1F()->Scale(scale);
244 hDirCosine->getTH1F()->Scale(scale);
245 hHOTime->getTH1F()->Scale(scale);
248 for (
int k=0;
k<5;
k++) {
249 hSigRing[
k]->getTH1F()->Scale(scale);
250 hPedRing[
k]->getTH1F()->Scale(scale);
253 for (
int k=0;
k<9;
k++) {
254 hSignal3x3[
k]->getTH1F()->Scale(scale);
T getUntrackedParameter(std::string const &, T const &) const
MonitorElement * book1D(const char *name, const char *title, int nchX, double lowX, double highX)
Book 1D histogram.
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")
DQMHOAlCaRecoStream(const edm::ParameterSet &)
bool getByType(Handle< PROD > &result) const
const T & max(const T &a, const T &b)
Tan< T >::type tan(const T &t)
virtual void analyze(const edm::Event &, const edm::EventSetup &)
void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
Power< A, B >::type pow(const A &a, const B &b)
void setCurrentFolder(const std::string &fullpath)