21 , primaryVertexInputTag_ ( primaryVertexInputTag )
22 , selectedPrimaryVertexInputTag_ ( selectedPrimaryVertexInputTag )
25 , NumberOfPVtxVsBXlumi(
NULL)
26 , NumberOfPVtxVsGoodPVtx(
NULL)
27 , NumberOfGoodPVtx(
NULL)
28 , NumberOfGoodPVtxVsBXlumi(
NULL)
29 , FractionOfGoodPVtx(
NULL)
30 , FractionOfGoodPVtxVsBXlumi(
NULL)
31 , FractionOfGoodPVtxVsGoodPVtx(
NULL)
32 , FractionOfGoodPVtxVsPVtx(
NULL)
33 , NumberOfBADndofPVtx(
NULL)
34 , NumberOfBADndofPVtxVsBXlumi(
NULL)
35 , NumberOfBADndofPVtxVsGoodPVtx(
NULL)
37 , GoodPVtxSumPtVsBXlumi(
NULL)
38 , GoodPVtxSumPtVsGoodPVtx(
NULL)
39 , GoodPVtxNumberOfTracks(
NULL)
40 , GoodPVtxNumberOfTracksVsBXlumi(
NULL)
41 , GoodPVtxNumberOfTracksVsGoodPVtx(
NULL)
42 , GoodPVtxNumberOfTracksVsGoodPVtxNdof(
NULL)
43 , GoodPVtxChi2oNDFVsGoodPVtx(
NULL)
44 , GoodPVtxChi2oNDFVsBXlumi(
NULL)
45 , GoodPVtxChi2ProbVsGoodPVtx(
NULL)
46 , GoodPVtxChi2ProbVsBXlumi(
NULL)
47 , doAllPlots_ ( conf_.getParameter<bool>(
"doAllPlots") )
48 , doPlotsVsBXlumi_ ( conf_.getParameter<bool>(
"doPlotsVsBXlumi") )
49 , doPlotsVsGoodPVtx_( conf_.getParameter<bool>(
"doPlotsVsGoodPVtx") )
93 size_t totalNumPV = 0;
94 size_t totalNumBADndofPV = 0;
99 totalNumPV = pvHandle->size();
101 for (reco::VertexCollection::const_iterator
pv = pvHandle->begin();
102 pv != pvHandle->end(); ++
pv) {
104 if (
pv->ndof() < 4.) totalNumBADndofPV++;
114 size_t totalNumGoodPV = 0;
118 totalNumGoodPV = selpvHandle->size();
126 double fracGoodPV = double(totalNumGoodPV)/double(totalNumPV);
140 if ( selpvHandle->size() ) {
144 double chi2prob = 0.;
146 if (!selpvHandle->at(0).isFake()) {
152 chi2prob = TMath::Prob(pv.
chi2(),(int)pv.
ndof());
156 double pt = (**itrk).pt();
228 int BXlumiBin = BXlumiParameters.
getParameter<
int>(
"BXlumiBin");
229 double BXlumiMin = BXlumiParameters.
getParameter<
double>(
"BXlumiMin");
230 double BXlumiMax = BXlumiParameters.
getParameter<
double>(
"BXlumiMax");
283 histname =
"Chi2ProbVsBXlumi_" +
label_;
289 histname =
"GoodPVtxChi2oNDFVsBXlumi_" +
label_;
295 histname =
"GoodPVtxChi2ProbVsBXlumi_" +
label_;
355 histname =
"GoodPVtxChi2ProbVsGoodPVtx_" +
label_;
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
T getParameter(std::string const &) const
edm::EDGetTokenT< reco::VertexCollection > pvToken_
MonitorElement * GoodPVtxNumberOfTracks
trackRef_iterator tracks_end() const
last iterator over tracks
MonitorElement * bookProfile(Args &&...args)
bool getByToken(EDGetToken token, Handle< PROD > &result) const
MonitorElement * GoodPVtxChi2oNDFVsBXlumi
MonitorElement * GoodPVtxSumPtVsBXlumi
MonitorElement * GoodPVtxNumberOfTracksVsBXlumi
std::vector< Vertex > VertexCollection
collection of Vertex objects
virtual void initHisto(DQMStore::IBooker &ibooker)
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
MonitorElement * NumberOfBADndofPVtxVsGoodPVtx
MonitorElement * GoodPVtxNumberOfTracksVsGoodPVtx
MonitorElement * GoodPVtxChi2oNDFVsGoodPVtx
MonitorElement * FractionOfGoodPVtxVsPVtx
double getValue(const edm::Event &)
void addDefault(ParameterSetDescription const &psetDescription)
void Fill(HcalDetId &id, double val, std::vector< TH2F > &depth)
edm::InputTag primaryVertexInputTag_
MonitorElement * Chi2oNDFVsBXlumi
MonitorElement * book1D(Args &&...args)
double chi2() const
chi-squares
MonitorElement * FractionOfGoodPVtx
MonitorElement * FractionOfGoodPVtxVsBXlumi
MonitorElement * GoodPVtxSumPtVsGoodPVtx
MonitorElement * NumberOfPVtxVsBXlumi
virtual void endLuminosityBlock(edm::LuminosityBlock const &, edm::EventSetup const &)
MonitorElement * NumberOfPVtxVsGoodPVtx
edm::EDGetTokenT< reco::VertexCollection > selpvToken_
MonitorElement * FractionOfGoodPVtxVsGoodPVtx
MonitorElement * NumberOfBADndofPVtx
void setCurrentFolder(const std::string &fullpath)
VertexMonitor(const edm::ParameterSet &, const edm::InputTag &, const edm::InputTag &, std::string pvLabel)
MonitorElement * GoodPVtxSumPt
MonitorElement * Chi2ProbVsBXlumi
MonitorElement * GoodPVtxChi2ProbVsGoodPVtx
edm::InputTag selectedPrimaryVertexInputTag_
MonitorElement * NumberOfGoodPVtxVsBXlumi
MonitorElement * GoodPVtxChi2ProbVsBXlumi
std::vector< TrackBaseRef >::const_iterator trackRef_iterator
The iteratator for the vector<TrackRef>
double normalizedChi2() const
chi-squared divided by n.d.o.f.
virtual void beginLuminosityBlock(edm::LuminosityBlock const &, edm::EventSetup const &)
MonitorElement * NumberOfBADndofPVtxVsBXlumi
trackRef_iterator tracks_begin() const
first iterator over tracks
void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
MonitorElement * NumberOfPVtx
virtual void analyze(const edm::Event &, const edm::EventSetup &)
size_t tracksSize() const
number of tracks
MonitorElement * NumberOfGoodPVtx