Exemplo n.º 1
0
axistitle = [
    'm1 p_{T} (GeV)', 'm2 p_{T} (GeV)', 'm1-m2 Inv Mass (GeV)',
    'm1 Gen p_{T} (GeV)', 'm2 Gen p_{T} (GeV)'
]

foldername = channel  #+"/fromHiggs"
if not os.path.exists(outputdir + '/' + foldername):
    os.makedirs(outputdir + '/' + foldername)

for n, h in enumerate(histoname):
    #    plotter.simpleplot_mc(foldername, ['VBF_LFV_HToMuTau_M125*', 'GluGlu_LFV_HToMuTau_M125*'], h[0], rebin=h[2], xaxis=h[1], leftside=False, xrange=None , preprocess=None, sort=True, forceLumi=1000)
    #    plotter.simpleplot_mc(foldername, 'WplusHToTauTau_M125*', h[0], rebin=h[2], xaxis=h[1], leftside=False, xrange=None , preprocess=None, sort=True, forceLumi=1000)
    plotter.plot_mc(foldername,
                    h,
                    1,
                    xaxis=axistitle[n],
                    leftside=False,
                    show_ratio=False,
                    ratio_range=1.5,
                    sort=False)
    #    plotter.plot_mc_vs_data(foldername, h, rebin=rebins[n], xaxis= axistitle[n], leftside=False, show_ratio=True, ratio_range=1.5, sort=True)
    plotter.save(foldername + '/' + h)

##canvas = ROOT.TCanvas("canvas","canvas",800,800)
##legend = ROOT.TLegend(0.2,0.8, 0.4, 0.7)
##LFVStack = ROOT.THStack("stack","")
##
##mypath = 'results/%s/LFVEMuAnalyserGen/' %jobid
##filelist = [f for f in listdir(mypath) if (isfile(join(mypath, f)) and 'data' not in f)]
##
###print lfvfilelist
###print smfilelist
Exemplo n.º 2
0
#plotter.mc_samples = mc_samples
for i in sign:
    for j in process:
        for k in ptcut:
            for nj in njets:

                for n, h in enumerate(histoname):
                    foldername = i + '/' + j + '/ept' + str(
                        int(k)) + '/' + str(int(nj))

                    #plotter.canvas.SetLogy(True)
                    plotter.plot_mc(foldername,
                                    ['ggHiggsToETau', 'vbfHiggToETau'],
                                    h[0],
                                    rebin=h[2],
                                    xaxis=h[1],
                                    leftside=False,
                                    show_ratio=False,
                                    ratio_range=1.5,
                                    rescale=10)
                    #plotter.simpleplot_mc(foldername,h[0], rebin=h[2], xaxis= h[1], leftside=False)
                    if not os.path.exists(outputdir + foldername):
                        os.makedirs(outputdir + foldername)

                    plotter.save(foldername + '/mc_' + h)

                    foldername = i + '/' + j + '/ept' + str(k) + '/' + str(
                        nj) + '/selected'
                    #plotter.canvas.SetLogy(True)
                    plotter.plot_mc(foldername,
                                    ['ggHiggsToETau', 'vbfHiggsToETau'],