scaling8To14[s] = gluino14TeV_NLO[s[0]] / gluino8TeV_NLONLL[s[0]] else: scaling8To14[s]=1. print "Signal scaling for",s,":", scaling8To14[s] cuts=[\ ("$\\ETmiss>100\\GeV$", "type1phiMet>100&&((singleElectronic&&nvetoMuons==0&&nvetoElectrons==1)||(singleMuonic&&nvetoMuons==1&&nvetoElectrons==0))"), ("$\\geq 1$ \\cPqb-tag", "nbtags>=1&&type1phiMet>100&&((singleElectronic&&nvetoMuons==0&&nvetoElectrons==1)||(singleMuonic&&nvetoMuons==1&&nvetoElectrons==0))"), ("$\\geq$4 jets", "njets>=4&&nbtags>=1&&type1phiMet>100&&((singleElectronic&&nvetoMuons==0&&nvetoElectrons==1)||(singleMuonic&&nvetoMuons==1&&nvetoElectrons==0))"), ("$\\HT\\geq 500$ \\GeV", "njets>=4&&nbtags>=1&&type1phiMet>100&&ht>500&&((singleElectronic&&nvetoMuons==0&&nvetoElectrons==1)||(singleMuonic&&nvetoMuons==1&&nvetoElectrons==0))"), ("$\\geq 2$ \\cPqb-tags", "njets>=4&&nbtags>=2&&type1phiMet>100&&ht>500&&((singleElectronic&&nvetoMuons==0&&nvetoElectrons==1)||(singleMuonic&&nvetoMuons==1&&nvetoElectrons==0))"), ("$\\geq$6 jets", "njets>=6&&nbtags>=2&&type1phiMet>100&&ht>500&&((singleElectronic&&nvetoMuons==0&&nvetoElectrons==1)||(singleMuonic&&nvetoMuons==1&&nvetoElectrons==0))"), ("$\\ETmiss\\geq 250$ \GeV", "njets>=6&&nbtags>=2&&type1phiMet>250&&ht>500&&((singleElectronic&&nvetoMuons==0&&nvetoElectrons==1)||(singleMuonic&&nvetoMuons==1&&nvetoElectrons==0))"), ("$\\mT>120$ \\GeV", "mT>120&&njets>=6&&nbtags>=2&&type1phiMet>250&&ht>500&&((singleElectronic&&nvetoMuons==0&&nvetoElectrons==1)||(singleMuonic&&nvetoMuons==1&&nvetoElectrons==0))"), ("$\\test$ \\GeV", "njets>=4&&nbtags==2&&type1phiMet>150&&ht>400&&((singleElectronic&&nvetoMuons==0&&nvetoElectrons==1)||(singleMuonic&&nvetoMuons==1&&nvetoElectrons==0))"), ] if not globals().has_key('chain'): chain={} for bkg in backgrounds: chain[(bkg)] = getBkgChain(dir = "/data/schoef/convertedTuples_v19/copyMET/", samples=(bkg)) for sig in signals: # chain[sig] = getSignalChain(sig[0], sig[1], "T1tttt", dir = "/data/adamwo/convertedTuples_v16/copyMET/") chain[sig] = getSignalChain(sig[0], sig[1], "T1tttt-madgraph", dir = "/data/schoef/convertedTuples_v19/copyMET/") print " & " + " & ".join([tableTexName[s] for s in backgrounds+signals])+"\\\\\\hline" for c in cuts: sstring = c[0]+" & " + " & ".join([str(round(getCutSignalYield(chain[s], c[1], "("+str(scaling8To14[s])+"*weight)", correctForFastSim = False, mtcut = None)['res'],1)) for s in backgrounds+signals]) if not c==cuts[-1]: sstring+="\\\\" print sstring
import ROOT from analysisHelpers import getCutSignalYield, getSignalChain sms = "T1tttt-madgraph" cut = "njets>=4&&nbtags>=2&&type1phiMet>200" mtc = [300, 500] c = getSignalChain(1150, 0, sms, dir='/data/schoef/convertedTuples_v19/copyMET/') res = getCutSignalYield(c, cut, mtc, "weight", correctForFastSim=True) print res c.IsA().Destructor(c) del c
import ROOT from analysisHelpers import getCutSignalYield, getSignalChain sms="T1tttt-madgraph" cut = "njets>=4&&nbtags>=2&&type1phiMet>200" mtc = [300,500] c = getSignalChain(1150, 0, sms, dir = '/data/schoef/convertedTuples_v19/copyMET/') res = getCutSignalYield(c, cut, mtc, "weight", correctForFastSim = True) print res c.IsA().Destructor(c) del c