ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/VHbb/python/plot_systematics.py
(Generate patch)

Comparing UserCode/VHbb/python/plot_systematics.py (file contents):
Revision 1.8 by peller, Mon Apr 8 09:00:05 2013 UTC vs.
Revision 1.9 by nmohr, Fri Jul 19 10:13:50 2013 UTC

# Line 1 | Line 1
1   #!/usr/bin/env python
2   import ROOT
3 + ROOT.gROOT.SetBatch(True)
4   from ROOT import TFile
5   from optparse import OptionParser
6   import sys
7   from myutils import BetterConfigParser, TdrStyles, getRatio
8  
8 ROOT.gROOT.SetBatch(True)
9  
10   argv = sys.argv
11   parser = OptionParser()
# Line 156 | Line 156 | for mass in masses:
156  
157  
158  
159
159                      ratioU.SetStats(0)
160                      ratioU.SetMinimum(0.01)
161                      ratioU.SetMaximum(2.49)
# Line 171 | Line 170 | for mass in masses:
170                      ratioU.GetXaxis().SetTitle('BDT output')
171                      ratioU.GetYaxis().SetTitle('Ratio')
172                      ratioU.Draw("hist")
173 +                    fitRatioU = ratioU.Fit("pol2","S")
174 +                    fitRatioU.Draw("SAME")
175                      ratioU.SetTitle("")
176                      ratioD.SetStats(0)
177                      ratioD.GetYaxis().SetRangeUser(0.5,1.5)
# Line 183 | Line 184 | for mass in masses:
184                      ratioD.SetLineStyle(3)
185                      ratioD.SetLineWidth(2)  
186                      ratioD.Draw("hist same")
187 +                    fitRatioD = ratioD.Fit("pol2","S")
188 +                    fitRatioD.Draw("SAME")
189                      ratioD.SetTitle("")
190                      m_one_line = ROOT.TLine(xMin,1,xMax,1)
191                      m_one_line.SetLineStyle(7)
# Line 192 | Line 195 | for mass in masses:
195  
196                      #name = outpath+Abin+'_M'+mass+'_'+channel+'_'+MC+syst+'.png'
197                      #c.Print(name)
198 <                    name = outpath+Abin+'_M'+mass+'_'+channel+'_'+MC+syst+'.pdf'
198 >                    name = outpath+'systPlot_'+Abin+'_M'+mass+'_'+channel+'_'+MC+syst+'.pdf'
199                      c.Print(name)
200  
201  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines