28 |
|
VHbbNameSpace=config.get('VHbbNameSpace','library') |
29 |
|
ROOT.gSystem.Load(VHbbNameSpace) |
30 |
|
|
31 |
< |
def get_histos_from_tree(self,job): |
31 |
> |
def get_histos_from_tree(self,job,cutOverWrite=None): |
32 |
|
if self.lumi == 0: |
33 |
|
raise Exception("You're trying to plot with no lumi") |
34 |
|
|
59 |
|
xMin=float(options['xMin']) |
60 |
|
xMax=float(options['xMax']) |
61 |
|
weightF=options['weight'] |
62 |
< |
treeCut='%s'%(options['cut']) |
62 |
> |
if cutOverWrite: |
63 |
> |
treeCut=cutOverWrite |
64 |
> |
else: |
65 |
> |
treeCut='%s'%(options['cut']) |
66 |
|
|
67 |
|
#options |
68 |
|
|
70 |
|
if CuttedTree.GetEntries(): |
71 |
|
if 'RTight' in treeVar or 'RMed' in treeVar: |
72 |
|
drawoption = '(%s)*(%s & %s)'%(weightF,treeCut,BDT_add_cut) |
73 |
+ |
#print drawoption |
74 |
|
else: |
75 |
|
drawoption = '(%s)*(%s)'%(weightF,treeCut) |
76 |
|
CuttedTree.Draw('%s>>%s(%s,%s,%s)' %(treeVar,name,nBins,xMin,xMax), drawoption, "goff,e") |