ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/L1RpcTriggerAnalysis/src/BestMuonFinder.cc
(Generate patch)

Comparing UserCode/L1RpcTriggerAnalysis/src/BestMuonFinder.cc (file contents):
Revision 1.5 by konec, Mon May 21 10:50:08 2012 UTC vs.
Revision 1.7 by konec, Tue Dec 11 13:21:39 2012 UTC

# Line 24 | Line 24
24   BestMuonFinder::BestMuonFinder(const edm::ParameterSet& cfg)
25    : lastEvent(0), lastRun(0), theConfig(cfg), theUnique(true), theMuon(0),
26      hMuChi2Tk(0), hMuChi2Gl(0), hMuNHitsTk(0),
27 <    hMuPtVsEta(0), hMuHitsRPCvsCSC(0), hMuHitsRPCvsDT(0)
27 >    hMuPtVsEta(0), hMuHitsRPCvsCSC(0), hMuHitsRPCvsDT(0),
28 >    hMuonPt_BMF(0),hMuonEta_BMF (0),hMuonPhi_BMF(0)
29   {}
30  
31   bool BestMuonFinder::run(const edm::Event &ev, const edm::EventSetup &es)
# Line 50 | Line 51 | bool BestMuonFinder::run(const edm::Even
51    for (reco::MuonCollection::const_iterator im = muons->begin(); im != muons->end(); ++im) {
52  
53      if (!im->isTrackerMuon() || !im->innerTrack().isNonnull()) continue;
54 +    if (hMuonPt_BMF)   hMuonPt_BMF->Fill( im->innerTrack()->pt());
55 +    if (hMuonEta_BMF) hMuonEta_BMF->Fill( im->innerTrack()->eta());
56 +    if (hMuonPhi_BMF) hMuonPhi_BMF->Fill( im->innerTrack()->phi());
57      if (hMuPtVsEta) hMuPtVsEta->Fill(im->innerTrack()->eta(), im->innerTrack()->pt());
58      if (im->innerTrack()->pt() < theConfig.getParameter<double>("minPt")) continue;
59      if (fabs(im->innerTrack()->eta()) >  theConfig.getParameter<double>("maxEta")) continue;
# Line 132 | Line 136 | void BestMuonFinder::initHistos( TObjArr
136    hMuHitsRPCvsCSC = new TH2D("hMuHitsRPCvsCSC","hMuHitsRPCvsCSC", 40,0.,40., 6,0.,6.); histos.Add(hMuHitsRPCvsCSC);
137    hMuHitsRPCvsDT  = new TH2D("hMuHitsRPCvsDT","hMuHitsRPCvsDT", 30,0.,60., 6,0.,6.); histos.Add(hMuHitsRPCvsDT);
138   //  hMuHitsCSCvsEta = new TH2D("hMuHitsCSCvsEta","hMuHitsCSCvsEta",17, 0.8,2.5, 40,0.,40); histos.Add(hMuHitsCSCvsEta);
139 +  hMuonPt_BMF  = new TH1D("hMuonPt_BMF","All global muons Pt;Glb.muon p_{T} [GeV];Muons / bin",L1PtScale::nPtBins,L1PtScale::ptBins);  histos.Add(hMuonPt_BMF);
140 +  hMuonEta_BMF = new TH1D("hMuonEta_BMF","All global muons Eta;Glb.muon #eta;Muons / bin",84, -2.1, 2.1);  histos.Add(hMuonEta_BMF);
141 +  hMuonPhi_BMF = new TH1D("hMuonPhi_BMF","All global muons Phi;Glb.muon #phi [rad];Muons / bin",90,-M_PI,M_PI);  histos.Add(hMuonPhi_BMF);
142 +
143   }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines