Changeset 9047a02 in git
- Timestamp:
- Dec 6, 2018, 8:19:01 AM (6 years ago)
- Branches:
- ImprovedOutputFile, Timing, dual_readout, llp, master
- Children:
- a7c3c84
- Parents:
- 01f9722
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
examples/Example1.C
r01f9722 r9047a02 30 30 TClonesArray *branchJet = treeReader->UseBranch("Jet"); 31 31 TClonesArray *branchElectron = treeReader->UseBranch("Electron"); 32 TClonesArray *branchEvent = treeReader->UseBranch("Event"); 32 33 33 34 // Book histograms … … 40 41 // Load selected branches with data from specified event 41 42 treeReader->ReadEntry(entry); 43 44 //HepMCEvent *event = (HepMCEvent*) branchEvent -> At(0); 45 //LHEFEvent *event = (LHEFEvent*) branchEvent -> At(0); 46 //Float_t weight = event->Weight; 42 47 43 48 // If event contains at least 1 jet … … 48 53 49 54 // Plot jet transverse momentum 50 histJetPT->Fill(jet->PT );55 histJetPT->Fill(jet->PT, weight); 51 56 52 57 // Print jet transverse momentum … … 64 69 65 70 // Plot their invariant mass 66 histMass->Fill(((elec1->P4()) + (elec2->P4())).M() );71 histMass->Fill(((elec1->P4()) + (elec2->P4())).M(), weight); 67 72 } 68 73 }
Note:
See TracChangeset
for help on using the changeset viewer.