19 , TopFolderName_ ( pSet.getParameter<std::
string>(
"TopFolderName") )
20 , AlignmentLabel_( pSet.getParameter<std::
string>(
"AlignmentLabel"))
84 nans[0] =
dqmStore_->
book1D(
"otherVtxNans",
"Illegal values for x,y,z,xx,xy,xz,yy,yz,zz (other Vtx)",9,0.5,9.5);
91 nans[1] =
dqmStore_->
book1D(
"tagVtxNans",
"Illegal values for x,y,z,xx,xy,xz,yy,yz,zz (tagged Vtx)",9,0.5,9.5);
98 xerr[0] =
dqmStore_->
book1D(
"otherErrX",
"Uncertainty x Coordinate (other Vtx)",100,-0.1,0.1);
99 yerr[0] =
dqmStore_->
book1D(
"otherErrY",
"Uncertainty y Coordinate (other Vtx)",100,-0.1,0.1);
100 zerr[0] =
dqmStore_->
book1D(
"otherErrZ",
"Uncertainty z Coordinate (other Vtx)",100,-20.,20.);
101 xerrVsTrks[0] =
dqmStore_->
book2D(
"otherErrVsWeightX",
"Uncertainty x Coordinate vs. track weight (other Vtx)",100,0,100.,100,-0.1,0.1);
102 yerrVsTrks[0] =
dqmStore_->
book2D(
"otherErrVsWeightY",
"Uncertainty y Coordinate vs. track weight (other Vtx)",100,0,100.,100,-0.1,0.1);
103 zerrVsTrks[0] =
dqmStore_->
book2D(
"otherErrVsWeightZ",
"Uncertainty z Coordinate vs. track weight (other Vtx)",100,0,100.,100,-0.1,0.1);
114 xerrVsTrks[1] =
dqmStore_->
book2D(
"tagErrVsWeightX",
"Uncertainty x Coordinate vs. track weight (tagged Vtx)",100,0,100.,100,0.,100);
115 yerrVsTrks[1] =
dqmStore_->
book2D(
"tagErrVsWeightY",
"Uncertainty y Coordinate vs. track weight (tagged Vtx)",100,0,100.,100,0.,100);
116 zerrVsTrks[1] =
dqmStore_->
book2D(
"tagErrVsWeightZ",
"Uncertainty z Coordinate vs. track weight (tagged Vtx)",100,0,100.,100,0.,100);
120 for (
int i=0;
i<2;++
i){
121 type[
i]->
getTH1F()->GetXaxis()->SetBinLabel(1,
"Valid, real");
122 type[
i]->getTH1F()->GetXaxis()->SetBinLabel(2,
"Valid, fake");
123 type[
i]->getTH1F()->GetXaxis()->SetBinLabel(3,
"Invalid");
171 ntracks =
dqmStore_->
book1D(
"ntracks",
"number of PV tracks (p_{T} > 1 GeV)", 3*TKNoBin, TKNoMin, (TKNoMax+0.5)*3.-0.5);
172 ntracks->
setAxisTitle(
"Number of PV Tracks (p_{T} > 1 GeV) per Event", 1);
173 ntracks->setAxisTitle(
"Number of Event", 2);
182 dxy =
dqmStore_->
book1D(
"dxy",
"PV tracks (p_{T} > 1 GeV) d_{xy} (cm)", DxyBin, DxyMin, DxyMax);
183 dz =
dqmStore_->
book1D(
"dz",
"PV tracks (p_{T} > 1 GeV) d_{z} (cm)", DzBin, DzMin, DzMax );
187 dxyVsPhi_pt1 =
dqmStore_->
bookProfile(
"dxyVsPhi_pt1",
"PV tracks (p_{T} > 1 GeV) d_{xy} (cm) VS track #phi",PhiBin, PhiMin, PhiMax, DxyBin, DxyMin, DxyMax,
"");
190 dzVsPhi_pt1 =
dqmStore_->
bookProfile(
"dzVsPhi_pt1",
"PV tracks (p_{T} > 1 GeV) d_{z} (cm) VS track #phi", PhiBin, PhiMin, PhiMax, DzBin, DzMin, DzMax,
"");
194 dxyVsEta_pt1 =
dqmStore_->
bookProfile(
"dxyVsEta_pt1",
"PV tracks (p_{T} > 1 GeV) d_{xy} (cm) VS track #eta",EtaBin, EtaMin, EtaMax, DxyBin, DxyMin, DxyMax,
"");
197 dzVsEta_pt1 =
dqmStore_->
bookProfile(
"dzVsEta_pt1",
"PV tracks (p_{T} > 1 GeV) d_{z} (cm) VS track #eta", EtaBin, EtaMin, EtaMax, DzBin, DzMin, DzMax,
"");
201 dxyVsPhi_pt10 =
dqmStore_->
bookProfile(
"dxyVsPhi_pt10",
"PV tracks (p_{T} > 1 GeV) d_{xy} (cm) VS track #phi",PhiBin, PhiMin, PhiMax, DxyBin, DxyMin, DxyMax,
"");
204 dzVsPhi_pt10 =
dqmStore_->
bookProfile(
"dzVsPhi_pt10",
"PV tracks (p_{T} > 10 GeV) d_{z} (cm) VS track #phi", PhiBin, PhiMin, PhiMax, DzBin, DzMin, DzMax,
"");
208 dxyVsEta_pt10 =
dqmStore_->
bookProfile(
"dxyVsEta_pt10",
"PV tracks (p_{T} > 10 GeV) d_{xy} (cm) VS track #eta",EtaBin, EtaMin, EtaMax, DxyBin, DxyMin, DxyMax,
"");
211 dzVsEta_pt10 =
dqmStore_->
bookProfile(
"dzVsEta_pt10",
"PV tracks (p_{T} > 10 GeV) d_{z} (cm) VS track #eta", EtaBin, EtaMin, EtaMax, DzBin, DzMin, DzMax,
"");
232 if (recVtxs.
isValid() ==
false || beamSpotHandle.
isValid()==
false){
234 <<
" Some products not available in the event: VertexCollection "
236 <<recVtxs.
isValid() <<
" BeamSpot "
238 <<beamSpotHandle.
isValid()<<
". Skipping plots for this event";
251 for(reco::VertexCollection::const_iterator
v=recVtxs->begin()+1;
252 v!=recVtxs->end(); ++
v){
287 if ( !isHighPurity )
continue;
289 float pt = (**t).pt();
290 if ( pt < 1. )
continue;
294 float eta = (**t).eta();
295 float phi = (**t).phi();
298 float chi2NDF = (**t).normalizedChi2();
299 float chi2Prob = TMath::Prob((**t).chi2(),(int)(**t).ndof());
300 float Dxy = (**t).dxy(myVertex);
301 float Dz = (**t).dz(myVertex);
302 float DxyErr = (**t).dxyError();
303 float DzErr = (**t).dzError();
322 if ( pt < 10. )
continue;
336 if (i < 0 || i > 1)
return;
339 else type[
i]->Fill(0.);
356 float xb = beamSpot.
x0() + beamSpot.
dxdz() * (v.
position().z() - beamSpot.
z0());
357 float yb = beamSpot.
y0() + beamSpot.
dydz() * (v.
position().z() - beamSpot.
z0());
373 for (
int k = 0;
k != 3;
k++) {
374 for (
int j =
k;
j != 3;
j++) {
std::string AlignmentLabel_
MonitorElement * xerrVsTrks[2]
T getParameter(std::string const &) const
double z0() const
z coordinate
MonitorElement * vtxndf[2]
MonitorElement * dxyVsEta_pt1
MonitorElement * dzVsPhi_pt10
MonitorElement * dzVsPhi_pt1
void pvTracksPlots(const reco::Vertex &v)
MonitorElement * book1D(const char *name, const char *title, int nchX, double lowX, double highX)
Book 1D histogram.
trackRef_iterator tracks_end() const
last iterator over tracks
void vertexPlots(const reco::Vertex &v, const reco::BeamSpot &beamSpot, int i)
bool getByToken(EDGetToken token, Handle< PROD > &result) const
double zError() const
error on z
#define DEFINE_FWK_MODULE(type)
MonitorElement * bsSigmaZ
edm::InputTag beamSpotInputTag_
bool isValid() const
Tells whether the vertex is valid.
double covariance(int i, int j) const
(i, j)-th element of error matrix, i, j = 0, ... 2
MonitorElement * dxyVsPhi_pt10
const double EtaMax[kNumberCalorimeter]
MonitorElement * xDiff[2]
const Point & position() const
position
MonitorElement * dzVsEta_pt1
MonitorElement * zerrVsTrks[2]
double dydz() const
dydz slope
MonitorElement * yerrVsTrks[2]
MonitorElement * dxyVsEta_pt10
void Fill(HcalDetId &id, double val, std::vector< TH2F > &depth)
float trackWeight(const TrackBaseRef &r) const
returns the weight with which a Track has contributed to the vertex-fit.
double chi2() const
chi-squares
float ChiSquaredProbability(double chiSquared, double nrDOF)
double BeamWidthX() const
beam width X
const double EtaMin[kNumberCalorimeter]
MonitorElement * vtxchi2[2]
MonitorElement * bookProfile(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, const char *option="s")
edm::EDGetTokenT< reco::BeamSpot > beamspotToken_
edm::EDGetTokenT< reco::VertexCollection > vertexToken_
double dxdz() const
dxdz slope
MonitorElement * dzVsEta_pt10
virtual void beginRun(const edm::Run &, const edm::EventSetup &)
edm::InputTag vertexInputTag_
std::string TopFolderName_
double xError() const
error on x
MonitorElement * chi2prob
XYZPointD XYZPoint
point in space with cartesian internal representation
MonitorElement * nbtksinvtx[2]
double sigmaZ() const
sigma z
TH1F * getTH1F(void) const
double BeamWidthY() const
beam width Y
std::vector< TrackBaseRef >::const_iterator trackRef_iterator
The iteratator for the vector<TrackRef>
double y0() const
y coordinate
MonitorElement * vtxprob[2]
trackRef_iterator tracks_begin() const
first iterator over tracks
MonitorElement * bsBeamWidthY
MonitorElement * book2D(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY)
Book 2D histogram.
void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
MonitorElement * yDiff[2]
double yError() const
error on y
MonitorElement * trksWeight[2]
void setCurrentFolder(const std::string &fullpath)
virtual void analyze(const edm::Event &iEvent, const edm::EventSetup &iSetup)
size_t tracksSize() const
number of tracks
PrimaryVertexMonitor(const edm::ParameterSet &pSet)
MonitorElement * bsBeamWidthX
MonitorElement * dxyVsPhi_pt1
double x0() const
x coordinate