CMS 3D CMS Logo

MCTruth2.py
Go to the documentation of this file.
1 from __future__ import print_function
2 from PhysicsTools.PythonAnalysis import *
3 from ROOT import gSystem
4 
5 # prepare the FWLite autoloading mechanism
6 gSystem.Load("libFWCoreFWLite.so")
7 ROOT.FWLiteEnabler.enable()
8 
9 # access the event tree
10 events = EventTree("generatorOutput.root")
11 
12 # event loop
13 for event in events:
14  genEvent = event.VtxSmeared.GetEvent()
15  print(genEvent)
void print(TMatrixD &m, const char *label=nullptr, bool mathematicaFormat=false)
Definition: Utilities.cc:47