24 nBookedBins =
histo->getNbinsX();
35 : valueLastTimeSlot(0), theFirstLS(firstLS), theLSPrescale(lsPrescale), doSlide(sliding), theMode(
mode) {
40 if (!sliding && theMode == 0)
41 LogWarning(
"DTDQM|DTMonitorModule|DTMonitorClient|DTTimeEvolutionHisto")
42 <<
"[DTTimeEvolutionHisto]***Error: wrong configuration" << endl;
44 stringstream realTitle;
45 realTitle <<
title <<
"/" << theLSPrescale <<
" LS";
53 histo->setBinLabel(1,
"avg. previous", 1);
57 for (
int bin = 1;
bin != nBookedBins + 1; ++
bin) {
59 if (theLSPrescale > 1) {
60 label <<
"LS " << ((
bin - 1) * theLSPrescale) + theFirstLS <<
"-" <<
bin * theLSPrescale + theFirstLS;
62 label <<
"LS " << ((
bin - 1) * theLSPrescale) + theFirstLS;
64 if (
bin % (2 * (
int)theLSPrescale) == 0)
74 : valueLastTimeSlot(0),
79 LogVerbatim(
"DTDQM|DTMonitorModule|DTMonitorClient|DTTimeEvolutionHisto")
80 <<
"[DTTimeEvolutionHisto] Retrieve ME with name: " 128 for (; nEventsIt != nEventsEnd; ++nEventsIt)
131 LogVerbatim(
"DTDQM|DTMonitorModule|DTMonitorClient|DTTimeEvolutionHisto")
149 for (; nLumiTrIt != nLumiTrEnd; ++nLumiTrIt)
150 nLumiTr += nLumiTrIt->second;
155 LogVerbatim(
"DTDQM|DTMonitorModule|DTMonitorClient|DTTimeEvolutionHisto")
159 stringstream binLabel;
160 binLabel <<
"LS " << firstLSinTimeSlot;
162 binLabel <<
"-" << lastLSinTimeSlot;
184 LogVerbatim(
"DTDQM|DTMonitorModule|DTMonitorClient|DTTimeEvolutionHisto")
185 <<
"[DTTimeEvolutionHisto] Update time-slot: " << binN <<
" with value: " <<
value << endl;
191 if (
histo ==
nullptr) {
192 LogWarning(
"DTDQM|DTMonitorModule|DTMonitorClient|DTTimeEvolutionHisto")
193 <<
"[DTTimeEvolutionHisto]***Error: pointer to ME is NULL" << endl;
198 LogWarning(
"DTDQM|DTMonitorModule|DTMonitorClient|DTTimeEvolutionHisto")
199 <<
"[DTTimeEvolutionHisto]***Error: normalizing histos with != # of bins" << endl;
205 LogVerbatim(
"DTDQM|DTMonitorModule|DTMonitorClient|DTTimeEvolutionHisto")
Log< level::Info, true > LogVerbatim
void accumulateValueTimeSlot(float value)
std::map< int, int > nLumiTrInLastTimeSlot
DTTimeEvolutionHisto(DQMStore::IBooker &ibooker, const std::string &name, const std::string &title, int nbins, int lsPrescale, bool sliding, int mode=0)
void setTimeSlotValue(float value, int timeSlot)
virtual ~DTTimeEvolutionHisto()
Destructor.
virtual void setBinLabel(int bin, const std::string &label, int axis=1)
set bin label for x, y or z axis (axis=1, 2, 3 respectively)
virtual void setBinContent(int binx, double content)
set content of bin (1-D)
virtual TH1F * getTH1F() const
void normalizeTo(const MonitorElement *histForNorm)
void updateTimeSlot(int ls, int nEventsInLS)
std::map< int, int > nEventsInLastTimeSlot
virtual int getNbinsX() const
get # of bins in X-axis
virtual double getBinError(int binx) const
get uncertainty on content of bin (1-D) - See TH1::GetBinError for details
virtual void setBinError(int binx, double error)
set uncertainty on content of bin (1-D)
Log< level::Warning, false > LogWarning
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
virtual double getBinContent(int binx) const
get content of bin (1-D)