예제 #1
0
    def plotIntegral(self, plot_orig, objectName, canvasName="Integral"):

        #        plot = copy.deepcopy(plot_orig)
        plot = plot_orig

        st = styles.getDataStyle().clone()
        st.append(styles.StyleFill(fillColor=ROOT.kYellow))

        plot.histoMgr.forHisto(objectName, st)
        plot.setFrameName(plot.cf.canvas.GetName() + canvasName)

        plot.draw()
        plot.save()

        st.append(styles.StyleFill(fillColor=0))
        plot.histoMgr.forHisto(objectName, st)
예제 #2
0
def transverseMass(plot):
    plot.histoMgr.forHisto("EWK", styles.StyleFill(styles.ttStyle))
    plot.stackMCHistograms()
    plot.setLegend(histograms.createLegend(0.7, 0.68, 0.9, 0.93))
    plot.createFrame("transverseMass")
    plot.frame.GetXaxis().SetTitle("m_{T}(#tau, MET) (GeV)")
    plot.frame.GetYaxis().SetTitle("Events / %.0f GeV" % plot.binWidth())
    plot.draw()
    plot.save()
예제 #3
0
def transverseMass(plot, name):
    plot.histoMgr.forHisto("EWK", styles.StyleFill(styles.ttStyle))
    plot.stackMCHistograms()
    plot.setLegend(histograms.createLegend(0.7, 0.68, 0.9, 0.93))
    plot.createFrame(name, opts={"ymin": 1e-1, "ymaxfactor": 10})
    # Set Y axis to logarithmic
    plot.getPad().SetLogy(True)
    plot.frame.GetXaxis().SetTitle("MET (GeV)")
    plot.frame.GetYaxis().SetTitle("Events / %.0f GeV" % plot.binWidth())
    plot.draw()
    # Add the various texts to
    plot.addStandardTexts()
    plot.save()