vector<reco::PFJet> "ak4PFJets" "" "RECO" vector<reco::PFJet> "ak4PFJetsCHS" "" "RECO" vector<reco::PFJet> "ak8PFJetsCHS" "" "RECO" vector<reco::PFJet> "pfJetsEI" "" "RECO" vector<reco::PFJet> "ak8PFJetsCHSSoftDrop" "SubJets" "RECO" vector<reco::PFJet> "cmsTopTagPFJetsCHS" "caTopSubJets" "RECO"You can loop over these collections as follows:
#include "DataFormats/JetReco/interface/PFJet.h" #include "DataFormats/JetReco/interface/PFJetCollection.h" edm::Handle<reco::PFJetCollection> pfjetH; iEvent.getByLabel("ak4PFJetsCHS", pfjetH); for ( reco::PFJetCollection::const_iterator jet = pfjetH->begin(); jet != pfjetH->end(); ++jet ) { double pt = jet->pt(); }You'll need to include the following in your BuildFile
<use name="DataFormats/JetReco"/>See the PFJet Class Reference
Reviewer/Editor and Date (copy from screen) | Comments |
---|---|
NitishDhingra - 2018-09-21 | Updated with latest instructions. Added missing twiki links of the necessary tools for doing jet analysis. |
Main.Aresh - 27 Feb 2008 | Changes in verbatim elements (in https://twiki.cern.ch/twiki/bin/edit/CMS/WorkBook160JetAnalysis) because of some lines too long for printable version |
FedorRatnikov - 01 Dec 2006 | separate pages for different releases, clean up main page |