#ifndef GUARD_TDSUBANA #define GUARD_TDSUBANA #include "mtuple.h" #include "TDHistSet.hh" #include #include #include "TDCanvMan.hh" #include "TF1.h" #include "TPaveText.h" #include #include "DilWeights.hh" //#include "DilLeptonType.hh" //#include "LeptonType.hh" #include "LeptonCat.hh" #include "TDMinMax.hh" #include "TDFlexCut.hh" #include "TDGroupCut.hh" #include "TDMtupCutInterface.hh" #include "TDMtupCutInterface_JESup.hh" #include "TDMtupCutInterface_JESdn.hh" #include "TDMtupCutInterface_LESup.hh" #include "TDMtupCutInterface_LESdn.hh" #include "TDAnaCutSet.hh" #include "TDNNAnaCutSet.hh" #include "TDDilSet.hh" #include "TDDilSetBMU.hh" #include "TDhwwlvlvGoodRun.hh" #include "TDhwwlvlvGoodRun17.hh" #include "TDUniqueMap.hh" #include "TDRunInfoSet.hh" #include "TDRunInfo.hh" #define PI 3.14159265 #include "TDMassPeakFit.hh" #include "TDVnEEE.hh" #include "TRandom.h" #include "TString.h" #include "./TMVA/src/Reader.h" //#include "root/include/TMVA/Reader.h" //for the mac #include "TMultiLayerPerceptron.h" #include "DFakeRates.h" #include "TDMatrix.hh" #include "TDStandardPlots.hh" #include "TDMassPlots.hh" #include "TDDilplots.hh" class TDSubAna: public mtuple { public: TDSubAna(char * datasource, bool isdata, bool debug, char * filename, TDCanvMan * CanvMan, int mydiltype, int weighting, TDRunSet& goodruns, char * runinfofile, float higgsMass, std::ofstream& latexcuttables, int minrun, int maxrun, int datasourceint, bool stn, bool mircea, float xs, bool wgammaerr, const char * fileLocation, bool sexo=false, bool sexo2=false)://, int colour): mtuple(filename, debug), _datasource(datasource), _isdata(isdata), _debug(debug), CanvMan1(CanvMan), _mydiltype(mydiltype), maxweight(0.0), //_dilWeight(DilWeights::JOINTPHYSICSV1),//OLDHWW),//JOINTPHYSICSV1), _leptonType(), _dilType(), Zinwindow(0), runmm("runnumber"), evtmm("eventnumber"), weightmm("weight"), dilweightmm("dilweight"), _jentrymm("jentry"), _passAll(false), _dilset(mydiltype), _weighttype(weighting), _hwwlvlvGoodRun(), _runstoignore("MCrunstoignore.txt"), //HistFill("dilDphiee_PDFdn", dildphi, weight*GetPDFError(false)); _thisrun(0), _thisZevents(0), _thisSS(0), _goodruns(goodruns), _sampleRunInfo(runinfofile), _totZevents(0), _totSS(0), _totWW(0), _higgsMass(higgsMass), _cutblockLat(latexcuttables), _dileptonmasshists("massplotst",("massplots in"+_datasource).c_str(),("massplots in"+_datasource).c_str(),CanvMan1,2,false), _debugruns("debugruns.txt"), _minRun(minrun), _maxRun(maxrun), _debugrunevt("debugrunevt.txt"), _datasourceint(datasourceint), weight(1.0), _myrand(0.0), _myrand2(0.0), _random(22345), _stn(stn), _mircea(mircea), _xs(xs), Use_Cuts(0), Use_Likelihood(0), Use_LikelihoodD(0), Use_PDERS(0), Use_HMatrix(0), Use_Fisher(0), Use_CFMlpANN(0), Use_TMlpANN(0), Use_BDT(0),//_GiniIndex(0), // default BDT method EvaluateVariables(0), initTMVA(false), _NNdiltype(0), _initTMLP(false), _initFakes(false), _matTest(0), _SaveRjn(false),//CONTROL _useSCMIO(false),//CONTROL _Mt_ll(0.0), _Mt_llMet(0.0), _Mt_All(0.0), _Isr(0.0), _DilPhillCorr(0.0), _saveNN(false), //CONTROL //_genNum_ee(0.0), //_genNum_emu(0.0), //_genNum_mumu(0.0), _eff_ee(0.0), _eff_emu(0.0), _eff_mumu(0.0), _this_runs_events(0), _fakeevent(0), _normalevent(0), _wgammaerr(wgammaerr), _sexo(sexo), _sexocombined(sexo2), _drawhists(false),//CONTROL _checknum1(0), _checknum2(0), _drawNNhists(true), //CONTROL _drawNNhists2(true), //CONTROL _drawNNhists3(true),//CONTROL _drawNNhists4(true),//CONTROL _drawNNhists5(true),//CONTROL _passNNDY(false), _7708Cutrejection(0),//CONTROL: replaces the NN DY cut with the cut from 7708. //DO NOT USE 2. (rubbish - legacy) //_fakes("FakeRates-28-09-06/FakeRates_v1_21.root") //_color(color) _removeNNtrain(false), //CONTROL _removeNNtrain_counter_0(0), _removeNNtrain_counter_1(0), _removeNNtrain_counter_2(0), _sexocomb_nat(false), //CONTROL: whether to use the scaling based on the generated number of not. (ture==not) _cmx_lum("CMXlum.rl"), _fileLocation(fileLocation), //_drawhists _histsDYDom(datasource,"DYDom",datasource), _histsDYDomHighM(datasource,"DYDomHighM",datasource), _histsDYDomLowM(datasource,"DYDomLowM",datasource), _histsHWWDom(datasource,"HWWDom",datasource), _histsWWDom(datasource,"WWDom",datasource), _histsWWDomMBox(datasource,"WWDomMBox",datasource), _histsWWDomOutMBox(datasource,"WWDomOutMBox",datasource), //NNhists2plots _histsNNDYCut(datasource,"NNDYCut",datasource), _histsLepEtControlNNDYCut(datasource,"LepEtControlNNDYCut",datasource), _histsNNInputVar(datasource,"NNInputVar",datasource), _histsLepEtControlNNInputVar(datasource,"LepEtControlNNInputVar",datasource), _histsHighMllControlNNInputVar(datasource,"HighMllControlNNInputVar",datasource), _histsHighMllControlNNDYCut(datasource,"HighMllControlNNDYCut",datasource), _histsZPeakNNInputVar(datasource,"ZPeakNNInputVar",datasource), _histsZPeakNNDYCut(datasource,"ZPeakNNDYCut",datasource), //hists3 _histsWWNNlowCut(datasource,"WWNNlowCut",datasource), _histsWWNNmidCut(datasource,"WWNNmidCut",datasource), _histsWWNNhighCut(datasource,"WWNNhighCut",datasource), //hists4 _histsNNDYCutMid(datasource, "NNDYCutMid", datasource), _histsLowMllControlNNInputVar(datasource, "LowMllControlNNInputVar", datasource), _histsLowMllControlNNDYCut(datasource, "LowMllControlNNDYCut", datasource), _zmass_mass(datasource, "mass", "Mass", 70.0, 120.0, 50), _zmass_040mass(datasource, "mass040", "Mass 0-40 Range", 0.0, 40.0, 40), _zmass_fullmass(datasource, "massfull", "Mass Full Range", 0.0, 200.0, 50), _rawweightplots(datasource, "rawweight", "HistSetDesc", 0.7, 1.1, 80), _relweighterrorplots(datasource, "relweighterror", "HistSetDesc", 0.0, 0.1, 100), _weightplots(datasource, "weight", "HistSetDesc", 0.7, 1.1, 80), //NNhists5 _histsLMetHMetSNNInputVar(datasource,"LMetHMetSNNInputVar",datasource), _histsLMetSHMetNNInputVar(datasource,"LMetSHMetNNInputVar",datasource) { SetEpsVtx(); // _hprof = new TProfile("hprof","Profile of dilmass versus lepBEt",100,0,200,0,200); for(int i=0;i!=3;++i) for(int j=0;j!=4;++j) _deancomp_metsig[i][j]=0; _passEtcut[0]=_passEtcut[1]=_passEtcut[2]=_passEtcut[3]=0.0; //_debugrunevt.PrintValues(); for(std::vector::iterator it=_debugrunevt.begin(); it!=_debugrunevt.end(); it++) _debugEvents.Insert((int)(it->_run),(int)(it->_hepgZ)); //_debugEvents.PrintValues(); if(_weighttype==2) _dilWeight = new (DilWeights)(DilWeights::JOINTPHYSICSV1, &_hwwlvlvGoodRun17, _minRun, _maxRun); else _dilWeight = new (DilWeights)(DilWeights::OLDHWW, &_hwwlvlvGoodRun17, _minRun, _maxRun); //std::cout<<"test test delete dilweight"<::iterator=(reducedrunset.end())--; //_maxrunfromZlog=*((reducedrunset.end())--); //_maxrunfromZlog=reducedrunset[reducedrunset.size()]; _maxrunfromZlog=*(reducedrunset.rbegin()); std::cout<<"max run: "<<_maxrunfromZlog<GetAnaHist("luminosity")->GetHist()->GetMean()<PrintTree(fitinfo); _anaCutSet->GetCutAnaCut()->PrintTree(fitinfo); _anaCutSet->GetCutAnaCut()->PrintTree(fitinfo, true); //fitinfo<::iterator it=_alldilcuts.begin(); it!=_alldilcuts.end(); it++) {delete *it;} for(std::vector::iterator it=_alldilcuts_0d.begin(); it!=_alldilcuts_0d.end(); it++) {delete *it;} for(std::vector::iterator it=_alldilcuts_0h.begin(); it!=_alldilcuts_0h.end(); it++) {delete *it;} for(std::vector::iterator it=_alldilcuts_0i.begin(); it!=_alldilcuts_0i.end(); it++) {delete *it;} for(std::vector::iterator it=_alldilcuts_0h0i.begin(); it!=_alldilcuts_0h0i.end(); it++) {delete *it;} for(std::vector::iterator it=_allNNdilcuts.begin(); it!=_allNNdilcuts.end(); it++) {delete *it;} for(std::vector::iterator it=_allNNdilcuts_0d.begin(); it!=_allNNdilcuts_0d.end(); it++) {delete *it;} for(std::vector::iterator it=_allNNdilcuts_0h.begin(); it!=_allNNdilcuts_0h.end(); it++) {delete *it;} for(std::vector::iterator it=_allNNdilcuts_0i.begin(); it!=_allNNdilcuts_0i.end(); it++) {delete *it;} for(std::vector::iterator it=_allNNdilcuts_0h0i.begin(); it!=_allNNdilcuts_0h0i.end(); it++) {delete *it;} } std::cout<<"beginning of deleting everything"<::iterator it=_fakevectord->begin(); it!=_fakevectord->end(); it++){if(*it!=NULL)delete *it; *it=0; std::cout<<"in loop"<::iterator it=_fakevectorh->begin(); it!=_fakevectorh->end(); it++){if(*it!=NULL)delete *it; *it=0;} std::cout<<"deleting fake elements"<::iterator it=_fakevectori->begin(); it!=_fakevectori->end(); it++){if(*it!=NULL)delete *it; *it=0;} std::cout<<"deleting fake elements"<Draw(); fitinfo<::iterator it=_deancomp_fakenumbers.begin(); it!=_deancomp_fakenumbers.end(); ++it) { fitinfo<<"deancomp fakenumbes: "<<_dilType.Int2StringDash(deancompveccounter)<<" "<<_deancomp_fakenumbers[deancompveccounter]<<" fakes: "<<_deancomp_fakes[deancompveccounter]<GetAnaHist("luminosity")->GetHist()->GetMean()<GetAnaHist("DileptonMass")->GetHist())); if(_drawhists)std::cout<<" Same sign events in Zmasspeak: "<<_subAnaHists->GetAnaHist("SameSignDilMass")->GetHist()->Integral()<GetAnaHist("SameSignDilMass")->GetHist()->Integral()<=4 && counter<=16))) { Massfile<<_dilType.Int2StringDash(counter)<<" "; testmasspeak.RangeMassfitter( ( * ( (TH1F*) ((*(_dileptonmasshists.GetAnaIt())) ->GetHist()) ) ), 87.0, 95.0); // ++counter; TDVnEEE mean=testmasspeak.GetVnEEEMean(); ExcelDataOut(mean, Massfile); Massfile<AddConcatenate(_relweighterrorplots); _subAnaHists->AddConcatenate(_weightplots); for(int type=DilType::TCE_TCE; type<=DilType::BMU_CMIO; ++type)//TD if no error available for diltype, take rms of weights & scale up. { //if(type==DilType::trilep)continue; if(_subAnaHists->GetAnaHist(((_dilType.Int2StringDash(type)) + " relweighterror").c_str())->GetHist()->Integral()==0) { HistFill( ((_dilType.Int2StringDash(type)) + " relweighterror").c_str(), (_subAnaHists->GetAnaHist(((_dilType.Int2StringDash(type)) + " weight").c_str())->GetHist()->GetRMS())/ (_subAnaHists->GetAnaHist(((_dilType.Int2StringDash(type)) + " weight").c_str())->GetHist()->GetMean()), _subAnaHists->GetAnaHist(((_dilType.Int2StringDash(type)) + " weight").c_str())->GetHist()->Integral()); HistFill("RelWeightError", (_subAnaHists->GetAnaHist(((_dilType.Int2StringDash(type)) + " weight").c_str())->GetHist()->GetRMS())/ (_subAnaHists->GetAnaHist(((_dilType.Int2StringDash(type)) + " weight").c_str())->GetHist()->GetMean()), _subAnaHists->GetAnaHist(((_dilType.Int2StringDash(type)) + " weight").c_str())->GetHist()->Integral());//TD add weight to all the other collected weighterrors } } //char buffer[500]; if(true)//if(_mydiltype==-1) { std::ofstream cutblock; // cutblock.open(("results/cutblock_"+_datasource+".txt").c_str()); sprintf(buffer,"results/cutblock_%s-%d.txt",_datasource.c_str(),(int)_higgsMass); cutblock.open(buffer); double effsum0d=0; double effsum0h=0; double effsum0i=0; double effsum0h0i=0; int counter=0; for(std::vector::iterator it=_alldilcuts.begin(); it!=_alldilcuts.end(); it++) { cutblock<<(*it)->Getname()<<" "; (*it)->GetCutAnaCut()->PrintCumulativeTreeinBlockForm(cutblock); cutblock<::iterator it=_alldilcuts_0d.begin(); it!=_alldilcuts_0d.end(); it++) { cutblock<<(*it)->Getname()<<" "; (*it)->GetCutAnaCut()->PrintCumulativeTreeinBlockForm(cutblock); cutblock<35 && counter<41))//no BMU in the analysis if(counter!=2 && counter!=4 && counter!=15 && counter!=16) //(*it)->GetCutAnaCut()->PrintValues(); //(*it)->GetCutAnaCut()->PrintCumulativeValues(); //std::cout<<"eff for "<GetCutAnaCut()->GetCut("LeptonE")->GetCutEff((int)GetInputEvents(counter))<GetCutAnaCut()->GetCut("LeptonE")->GetCutEff((int)GetInputEvents(counter)); ++counter; } counter=0; for(std::vector::iterator it=_alldilcuts_0h.begin(); it!=_alldilcuts_0h.end(); it++) { cutblock<<(*it)->Getname()<<" "; (*it)->GetCutAnaCut()->PrintCumulativeTreeinBlockForm(cutblock); cutblock<35 && counter<41))//no BMU in the analysis if(counter!=2 && counter!=4 && counter!=15 && counter!=16) effsum0h+=(*it)->GetCutAnaCut()->GetCut("LeptonE")->GetCutEff((int)GetInputEvents(counter)); ++counter; } counter=0; for(std::vector::iterator it=_alldilcuts_0i.begin(); it!=_alldilcuts_0i.end(); it++) { cutblock<<(*it)->Getname()<<" "; (*it)->GetCutAnaCut()->PrintCumulativeTreeinBlockForm(cutblock); cutblock<35 && counter<41))//no BMU in the analysis if(counter!=2 && counter!=4 && counter!=15 && counter!=16) effsum0i+=(*it)->GetCutAnaCut()->GetCut("LeptonE")->GetCutEff((int)GetInputEvents(counter)); ++counter; } counter=0; for(std::vector::iterator it=_alldilcuts_0h0i.begin(); it!=_alldilcuts_0h0i.end(); it++) { cutblock<<(*it)->Getname()<<" "; (*it)->GetCutAnaCut()->PrintCumulativeTreeinBlockForm(cutblock); cutblock<35 && counter<41))//no BMU in the analysis if(counter!=2 && counter!=4 && counter!=15 && counter!=16) effsum0h0i+=(*it)->GetCutAnaCut()->GetCut("LeptonE")->GetCutEff((int)GetInputEvents(counter)); ++counter; } counter=0; //cutblock.close(); //std::ofstream _cutblockLat; //_cutblockLat.open(("results/cutblock_"+_datasource+".tex").c_str()); _cutblockLat<<" \\begin{table}[H] \\begin{sideways}"< "<::iterator it=_alldilcuts.begin(); it!=_alldilcuts.end(); it++)//run through the dilepton types printing out the cut statistics { //std::cout<<"in TDAnaCutSet loop"<Getname()<<" & "<Getname()<<" & & "; //_genNum_ee=subtotinputevents; //TD save subtotal events for later _anaCutSetee->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, subtotinputevents); //prints the cut efficiency _anaCutSetee->GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents(), subtoteff); //prints the cut efficiency _cutblockLat<Getname()<<" & & "; //_genNum_emu=subtotinputevents; //TD save subtotal events for later _anaCutSetemu->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, subtotinputevents);//prints the cut efficiency _anaCutSetemu->GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents(), subtoteff); _cutblockLat<Getname()<<" & "; _anaCutSetmumu->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, subtotinputevents);//prints the cut efficiency _cutblockLat<35 && counter<41))//no BMU in the analysis if(counter!=2 && counter!=4 && counter!=15 && counter!=16) { //std::cout<<"counter: "<Getname()<<" & "<GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents(counter));//prints the cut efficiency _cutblockLat<GetCutAnaCut()->GetCut("LeptonE")->GetCutEff((int)GetInputEvents(counter)); } // delete *it; ++counter; } _cutblockLat<<_anaCutSetmumu->Getname()<<" & & "; //_genNum_mumu=subtotinputevents; //TD save subtotal events for later _anaCutSetmumu->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, subtotinputevents);//prints the cut efficiency _anaCutSetmumu->GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents(), subtoteff); _cutblockLat<Getname()<<" & "<< GetInputEvents()<<" & "; _anaCutSet->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents()); _cutblockLat<Getname()<<" & & "; _anaCutSet0d->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents0d(), effsum0d);//prints the cut efficiency _cutblockLat<Getname()<<" & & "; _anaCutSet0h->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents0h(), effsum0h);//prints the cut efficiency _cutblockLat<Getname()<<" & & "; _anaCutSet0i->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents0i(), effsum0i);//prints the cut efficiency _cutblockLat<Getname()<<" & & "; _anaCutSet0h0i->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents0h()+GetInputEvents0i(), effsum0h0i);//prints the cut efficiency _cutblockLat<::iterator it=_allNNdilcuts.begin(); it!=_allNNdilcuts.end(); it++) { cutblock<<(*it)->Getname()<<" "; (*it)->GetCutAnaCut()->PrintCumulativeTreeinBlockForm(cutblock); cutblock<::iterator it=_allNNdilcuts_0d.begin(); it!=_allNNdilcuts_0d.end(); it++) { cutblock<<(*it)->Getname()<<" "; (*it)->GetCutAnaCut()->PrintCumulativeTreeinBlockForm(cutblock); cutblock<35 && NNcounter<41))//no BMU in the analysis if(NNcounter!=2 && NNcounter!=4 && NNcounter!=15 && NNcounter!=16) //(*it)->GetCutAnaCut()->PrintValues(); //(*it)->GetCutAnaCut()->PrintCumulativeValues(); //std::cout<<"eff for "<GetCutAnaCut()->GetCut("LeptonE")->GetCutEff((int)GetInputEvents(NNcounter))<GetCutAnaCut()->GetCut("LeptonE")->GetCutEff((int)GetInputEvents(NNcounter)); ++NNcounter; } NNcounter=0; for(std::vector::iterator it=_allNNdilcuts_0h.begin(); it!=_allNNdilcuts_0h.end(); it++) { cutblock<<(*it)->Getname()<<" "; (*it)->GetCutAnaCut()->PrintCumulativeTreeinBlockForm(cutblock); cutblock<35 && NNcounter<41))//no BMU in the analysis if(NNcounter!=2 && NNcounter!=4 && NNcounter!=15 && NNcounter!=16) NNeffsum0h+=(*it)->GetCutAnaCut()->GetCut("LeptonE")->GetCutEff((int)GetInputEvents(NNcounter)); ++NNcounter; } NNcounter=0; for(std::vector::iterator it=_allNNdilcuts_0i.begin(); it!=_allNNdilcuts_0i.end(); it++) { cutblock<<(*it)->Getname()<<" "; (*it)->GetCutAnaCut()->PrintCumulativeTreeinBlockForm(cutblock); cutblock<35 && NNcounter<41))//no BMU in the analysis if(NNcounter!=2 && NNcounter!=4 && NNcounter!=15 && NNcounter!=16) NNeffsum0i+=(*it)->GetCutAnaCut()->GetCut("LeptonE")->GetCutEff((int)GetInputEvents(NNcounter)); ++NNcounter; } NNcounter=0; for(std::vector::iterator it=_allNNdilcuts_0h0i.begin(); it!=_allNNdilcuts_0h0i.end(); it++) { cutblock<<(*it)->Getname()<<" "; (*it)->GetCutAnaCut()->PrintCumulativeTreeinBlockForm(cutblock); cutblock<35 && NNcounter<41))//no BMU in the analysis if(NNcounter!=2 && NNcounter!=4 && NNcounter!=15 && NNcounter!=16) NNeffsum0h0i+=(*it)->GetCutAnaCut()->GetCut("LeptonE")->GetCutEff((int)GetInputEvents(NNcounter)); ++NNcounter; } NNcounter=0; cutblock.close(); //std::ofstream _cutblockLat; //_cutblockLat.open(("results/cutblock_"+_datasource+".tex").c_str()); _cutblockLat<<" \\begin{table}[H] \\begin{sideways}"< "<::iterator it=_allNNdilcuts.begin(); it!=_allNNdilcuts.end(); it++)//run through the dilepton types printing out the cut statistics { //std::cout<<"in TDNNAnaCutSet loop"<Getname()<<" & "<Getname()<<" & & "; //_genNum_ee=NNsubtotinputevents; //TD save subtotal events for later _anaNNCutSetee->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, NNsubtotinputevents); //prints the cut efficiency _anaNNCutSetee->GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents(), NNsubtoteff); //prints the cut efficiency _cutblockLat<Getname()<<" & & "; //_genNum_emu=NNsubtotinputevents; //TD save subtotal events for later _anaNNCutSetemu->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, NNsubtotinputevents);//prints the cut efficiency _anaNNCutSetemu->GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents(), NNsubtoteff); _cutblockLat<Getname()<<" & "; _anaNNCutSetmumu->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, NNsubtotinputevents);//prints the cut efficiency _cutblockLat<35 && NNcounter<41))//no BMU in the analysis if(NNcounter!=2 && NNcounter!=4 && NNcounter!=15 && NNcounter!=16) { //std::cout<<"NNcounter: "<Getname()<<" & "<GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents(NNcounter));//prints the cut efficiency _cutblockLat<GetCutAnaCut()->GetCut("LeptonE")->GetCutEff((int)GetInputEvents(NNcounter)); } // delete *it; ++NNcounter; } _cutblockLat<<_anaNNCutSetmumu->Getname()<<" & & "; //_genNum_mumu=NNsubtotinputevents; //TD save subtotal events for later _anaNNCutSetmumu->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, NNsubtotinputevents);//prints the cut efficiency _anaNNCutSetmumu->GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents(), NNsubtoteff); _cutblockLat<Getname()<<" & "<< GetInputEvents()<<" & "; _anaNNCutSet->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents()); _cutblockLat<Getname()<<" & & "; _anaNNCutSet0d->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents0d(), NNeffsum0d);//prints the cut efficiency _cutblockLat<Getname()<<" & & "; _anaNNCutSet0h->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents0h(), NNeffsum0h);//prints the cut efficiency _cutblockLat<Getname()<<" & & "; _anaNNCutSet0i->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents0i(), NNeffsum0i);//prints the cut efficiency _cutblockLat<Getname()<<" & & "; _anaNNCutSet0h0i->GetCutAnaCut()->PrintCumulativeTreeinLatForm(_cutblockLat); //prints the passed numbers _cutblockLat<GetCutAnaCut()->PrintCumulativeEffTreeinLatForm(_cutblockLat, GetInputEvents0h()+GetInputEvents0i(), effsum0h0i);//prints the cut efficiency _cutblockLat<AddConcatenate(_histsDYDom); _subAnaHists->AddConcatenate(_histsDYDomHighM); _subAnaHists->AddConcatenate(_histsDYDomLowM); _subAnaHists->AddConcatenate(_histsHWWDom); _subAnaHists->AddConcatenate(_histsWWDom); _subAnaHists->AddConcatenate(_histsWWDomMBox); _subAnaHists->AddConcatenate(_histsWWDomOutMBox); } if(_drawNNhists2){ _subAnaHists->AddConcatenate(_histsNNDYCut); _subAnaHists->AddConcatenate(_histsLepEtControlNNDYCut); _subAnaHists->AddConcatenate(_histsNNInputVar); _subAnaHists->AddConcatenate(_histsLepEtControlNNInputVar); } if(_drawNNhists){ _subAnaHists->AddConcatenate(_histsHighMllControlNNInputVar); _subAnaHists->AddConcatenate(_histsHighMllControlNNDYCut); _subAnaHists->AddConcatenate(_histsZPeakNNInputVar); _subAnaHists->AddConcatenate(_histsZPeakNNDYCut); } if(_drawNNhists3){ _subAnaHists->AddConcatenate(_histsWWNNlowCut); _subAnaHists->AddConcatenate(_histsWWNNmidCut); _subAnaHists->AddConcatenate(_histsWWNNhighCut); } if (_drawNNhists4){ _subAnaHists->AddConcatenate(_histsNNDYCutMid); _subAnaHists->AddConcatenate(_histsLowMllControlNNInputVar); _subAnaHists->AddConcatenate(_histsLowMllControlNNDYCut); } if (_drawNNhists5){ _subAnaHists->AddConcatenate(_histsLMetHMetSNNInputVar); _subAnaHists->AddConcatenate(_histsLMetSHMetNNInputVar); } if(_drawhists)_subAnaHists->AddConcatenate(_zmass_mass); _subAnaHists->AddConcatenate(_zmass_040mass); _subAnaHists->AddConcatenate(_zmass_fullmass); _subAnaHists->AddConcatenate(_rawweightplots); } void FillPDFHists() { //if(_datasource=="higgsww") //{ GetPDFError(true, "dilDphiee_PDFup", "dilDphiee_PDF", "dilDphiee"); GetPDFError(false, "dilDphiee_PDFdn", "dilDphiee_PDF", "dilDphiee"); GetPDFError(true, "dilDphiemu_PDFup", "dilDphiemu_PDF", "dilDphiemu"); GetPDFError(false, "dilDphiemu_PDFdn", "dilDphiemu_PDF", "dilDphiemu"); GetPDFError(true, "dilDphimumu_PDFup", "dilDphimumu_PDF", "dilDphimumu"); GetPDFError(false, "dilDphimumu_PDFdn", "dilDphimumu_PDF", "dilDphimumu"); GetPDFError(true, "dilDphi_PDFup", "dilDphi_PDF", "TomdilDphi"); GetPDFError(false, "dilDphi_PDFdn", "dilDphi_PDF", "TomdilDphi"); //} //if(initTMVA)GetPDFError(true, "MVA2_TMlpANN_cut1_PDFup", "MVA2_TMlpANN_cut1_PDF", "MVA2_TMlpANN_cut1"); //if(initTMVA)GetPDFError(false, "MVA2_TMlpANN_cut1_PDFdn", "MVA2_TMlpANN_cut1_PDF", "MVA2_TMlpANN_cut1"); if(initTMVA)GetPDFError(true, "MVA2_TMlpANN_cut1_PDFup_ee", "MVA2_TMlpANN_cut1_PDF_ee", "MVA2_TMlpANN_cut1_ee"); if(initTMVA)GetPDFError(false, "MVA2_TMlpANN_cut1_PDFdn_ee", "MVA2_TMlpANN_cut1_PDF_ee", "MVA2_TMlpANN_cut1_ee"); if(initTMVA)GetPDFError(true, "MVA2_TMlpANN_cut1_PDFup_emu", "MVA2_TMlpANN_cut1_PDF_emu", "MVA2_TMlpANN_cut1_emu"); if(initTMVA)GetPDFError(false, "MVA2_TMlpANN_cut1_PDFdn_emu", "MVA2_TMlpANN_cut1_PDF_emu", "MVA2_TMlpANN_cut1_emu"); if(initTMVA)GetPDFError(true, "MVA2_TMlpANN_cut1_PDFup_mumu", "MVA2_TMlpANN_cut1_PDF_mumu", "MVA2_TMlpANN_cut1_mumu"); if(initTMVA)GetPDFError(false, "MVA2_TMlpANN_cut1_PDFdn_mumu", "MVA2_TMlpANN_cut1_PDF_mumu", "MVA2_TMlpANN_cut1_mumu"); } bool isData(){return _isdata;} //=======================================================================================beginning of main loop ==================================================================================================================================== void ProtectedEvent(Int_t entry, int jentry) { float cmx_runlum_ratio=-1; _this_runs_events++; if(_thisrun!=run)//BMU included { _thisrun=run; //if(_thisrun==156464)std::cout<<_thisrun<<" "<<_thisZevents<<" "<<_thisSS<<" "<<0<=222884) for(int i=0; i!=(int)(_cmx_lum.size()); i++) if((_cmx_lum)[i]._run==run) { //std::cout<<"run found:"< _maxRun))return; //for(int lep=0; lep 0.504)return; //"<" for test if(_removeNNtrain && (_datasource=="Ztautau" || _datasource=="Zmumu" || _datasource=="Zee") && _myrand < 0.099)return; //_SetPhxCorFac(_isdata); //if(diltype==1 && dilmass<25) return; //if(_sexocombined)for(int lep=0; lep200)return; //if(diltype!=23)return; //if(_isdata && evt> 1000000)std::cout<<"fake event:"<=10 && _isdata){std::cout<<"fake lep type: "<=10)fakeevent=true; //fake event? if(fakeevent && FakeSubEvNo==0)std::cout<<"fake lepton in normal event"<76.0 && dilmass <106.0)return; //take the Z peak out of the fakes. //if(_debugruns.IsGood(run))debugrun=true; //if(_mydiltype == -1 && (run < _minRun || run > _maxRun))return; if(run==154069 && evt==2771026) { std::cout<<"explicit debug2"<CalculateCutValues(); _cutInterface_JESup->CalculateCutValues(); _cutInterface_JESdn->CalculateCutValues(); _cutInterface_LESup->CalculateCutValues(); _cutInterface_LESdn->CalculateCutValues(); if(!_dilset.CorrectDilType(diltype))return; //TD diltype requirement if(debugrun)std::cout<<"5run: "<25) { if(debugrun)std::cout<<"no BMU for now"<186598)return; //gen 5 //if(_mydiltype == -1 && run <186599)return; if(debugrun)std::cout<<"run: "< VecForSumMt; for(int lep=0; lep=0 && lepPhi[lep]<(75*2*PI/360))|| (lepEtaDet[lep]>0 && lepPhi[lep]>(105*2*PI/360) && lepPhi[lep]<(225*2*PI/360))|| (lepEtaDet[lep]<0 && lepPhi[lep]>(105*2*PI/360) && lepPhi[lep]<(210*2*PI/360))|| (lepPhi[lep]>=(315*2*PI/360) && lepPhi[lep]<(2*PI)) ) )_badCMXWedge++; if(_badCMXWedge && debugrun)std::cout<<"bad cmx wedge"<35 && diltype<41))//no BMU in the analysis { if(_datasource=="fake") { (_alldilcuts[diltype])->changeFakeIsol(); _anaCutSet->changeFakeIsol(); //TD cuts are usually freezed to prevent constsnt recalculation; so we have to unfreeze from last event. if(diltype<=4) { _anaCutSetee->changeFakeIsol(); }else if(diltype>=17 && diltype<=25){ _anaCutSetmumu->changeFakeIsol(); }else if(diltype<17 && diltype >4){ _anaCutSetemu->changeFakeIsol(); } _anaCutSet_JESup->changeFakeIsol(); //TD same for high JES _anaCutSet_JESdn->changeFakeIsol(); //TD same for high JES _anaCutSet_LESup->changeFakeIsol(); //TD same for high LES _anaCutSet_LESdn->changeFakeIsol(); //TD same for high LES if(run<186599)//TD fill the anacuts for the total in the 0d, 0h, and 0i samples. { _anaCutSet0d->changeFakeIsol(); (_alldilcuts_0d[diltype])->changeFakeIsol(); }else if(run<= 203799&& run>186599){ _anaCutSet0h->changeFakeIsol(); (_alldilcuts_0h[diltype])->changeFakeIsol(); }else if(run< 212133&& run>203799){ _anaCutSet0i->changeFakeIsol(); (_alldilcuts_0i[diltype])->changeFakeIsol(); } if(run< 212133&& run >186599) { _anaCutSet0h0i->changeFakeIsol(); (_alldilcuts_0h0i[diltype])->changeFakeIsol(); } } } if(diltype<26 || (_useSCMIO && diltype>35 && diltype<41))//no BMU in the analysis { if(_mydiltype==-1) // && !samesign) //one of the cut is same sign; // && _badCMXRCot==0 && _badCMXWedge==0 ) //should be implemented when ready. { //if(_datasource=="data")filedump<UnFreeze(); (_alldilcuts[diltype])->PassAnaCut(); (_alldilcuts[diltype])->PassCumulateCut(); } //if( _badCMXRCot==0 && _badCMXWedge==0) //should be implemented when ready. passanacuts=false; // _cutInterface->CalculateCutValues(); _anaCutSet->UnFreeze(); //TD cuts are usually freezed to prevent constsnt recalculation; so we have to unfreeze from last event. _anaCutSet->PassAnaCut(); passanacuts = _anaCutSet->PassCumulateCut(); //TD store normal cut pass in handy bool.. _anaCutSet->GetCutAnaCut()->FlagNm1(); //TD FlagNm1 does check to see if only one cut was not passed and to flag the cut. if(diltype<=4) { _anaCutSetee->UnFreeze(); _anaCutSetee->PassAnaCut(); _anaCutSetee->PassCumulateCut(); _anaCutSetee->GetCutAnaCut()->FlagNm1(); }else if(diltype>=17 && diltype<=25){ _anaCutSetmumu->UnFreeze(); _anaCutSetmumu->PassAnaCut(); _anaCutSetmumu->PassCumulateCut(); _anaCutSetmumu->GetCutAnaCut()->FlagNm1(); }else if(diltype<17 && diltype >4){ _anaCutSetemu->UnFreeze(); _anaCutSetemu->PassAnaCut(); _anaCutSetemu->PassCumulateCut(); _anaCutSetemu->GetCutAnaCut()->FlagNm1(); } _anaCutSet_JESup->UnFreeze(); //TD same for high JES _anaCutSet_JESup->PassAnaCut(); _anaCutSet_JESup->GetCutAnaCut()->FlagNm1(); _anaCutSet_JESdn->UnFreeze(); //TD same for high JES _anaCutSet_JESdn->PassAnaCut(); _anaCutSet_JESdn->GetCutAnaCut()->FlagNm1(); _anaCutSet_LESup->UnFreeze(); //TD same for high LES _anaCutSet_LESup->PassAnaCut(); _anaCutSet_LESup->GetCutAnaCut()->FlagNm1(); _anaCutSet_LESdn->UnFreeze(); //TD same for high LES _anaCutSet_LESdn->PassAnaCut(); _anaCutSet_LESdn->GetCutAnaCut()->FlagNm1(); if(run<186599)//TD fill the anacuts for the total in the 0d, 0h, and 0i samples. { _anaCutSet0d->UnFreeze(); _anaCutSet0d->PassAnaCut(); _anaCutSet0d->PassCumulateCut(); _anaCutSet0d->FlagNm1(); (_alldilcuts_0d[diltype])->UnFreeze(); (_alldilcuts_0d[diltype])->PassAnaCut(); (_alldilcuts_0d[diltype])->PassCumulateCut(); }else if(run<= 203799&& run>186599){ _anaCutSet0h->UnFreeze(); _anaCutSet0h->PassAnaCut(); _anaCutSet0h->PassCumulateCut(); _anaCutSet0h->FlagNm1(); (_alldilcuts_0h[diltype])->UnFreeze(); (_alldilcuts_0h[diltype])->PassAnaCut(); (_alldilcuts_0h[diltype])->PassCumulateCut(); ++_checknum1; }else if(run< 212133&& run>203799){ _anaCutSet0i->UnFreeze(); _anaCutSet0i->PassAnaCut(); _anaCutSet0i->PassCumulateCut(); _anaCutSet0i->FlagNm1(); (_alldilcuts_0i[diltype])->UnFreeze(); (_alldilcuts_0i[diltype])->PassAnaCut(); (_alldilcuts_0i[diltype])->PassCumulateCut(); ++_checknum1; } if(run< 212133&& run >186599) { _anaCutSet0h0i->UnFreeze(); _anaCutSet0h0i->PassAnaCut(); _anaCutSet0h0i->PassCumulateCut(); _anaCutSet0h0i->FlagNm1(); (_alldilcuts_0h0i[diltype])->UnFreeze(); (_alldilcuts_0h0i[diltype])->PassAnaCut(); (_alldilcuts_0h0i[diltype])->PassCumulateCut(); ++_checknum2; } } DebugOut("ENDOF passing analysis cuts"); //TD ENDOF see which if events passes any of the analysis cuts for various cases ++++++++++++++ _lepR=sqrt(((lepEta[0]-lepEta[1])*(lepEta[0]-lepEta[1]))+((dildphi)*(dildphi))); //if(_lepR>PI)_lepR=(2*PI)-_lepR; //TD cannot use this at the moment because using old variables _NNdiltype=-1; //TD default - bad dilepton! if(diltype==DilType::TCE_TCE || diltype==DilType::TCE_PHX || diltype==DilType::PHX_PHX)_NNdiltype=0; //e-e else if((diltype>=DilType::TCE_CMUP && diltype<=DilType::PHX_CMIO) || diltype==DilType::TCE_BMU || diltype==DilType::PHX_BMU || diltype==DilType::TCE_SCMIO|| diltype==DilType::PHX_SCMIO)_NNdiltype=1; //e-mu else if((diltype>=DilType::CMUP_CMUP && diltype<=DilType::CMX_CMIO) || (diltype>=DilType::CMUP_BMU && diltype<=DilType::BMU_CMIO) || (diltype>=DilType::CMUP_SCMIO&& diltype<=DilType::BMU_SCMIO))_NNdiltype=2; //TD for same type dileptons - useful for the tmva analysis. /*if(_thisrun!=run && _thisrun!=0)//BMU included { if(_thisrun==156464)std::cout<<_thisrun<<" "<<_thisZevents<<" "<<_thisSS<<" "<<0<35 && diltype<41))//no BMU in this until their energies are sorted out. if(_drawhists)HistFill("HepGZDileptonMass", hepgZmass[0], 1); int goodlep=0; for(int lep=0; lep 20.0 && lepType[lep]!=8)goodlep++; //no BMU - I'm hoping this will be enough to remove BMU from the future code. if(goodlep>2)std::cout<<"trilep: "< 20.0) for(int lep2=0; lep2 10.0 && lep2!=lep) gooddilep++; if(lepEt[lep2] > 10.0 && lepEt[lep2] < 20.0 && lep2!=lep) dilep1020++; } //TD Weights calculation ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ DebugOut("Weights calculation"); //double weight; double weighterror=0.0; rawweight=1; luminosityweight=1; //double luminostyweight_sexo=1; weight=1; gennumberweight=1; goodZweight=1; if(_weighttype==0) { rawweight=1; weighterror=0; }else{ if(debugrun)_dilWeight->SetDebug(true); if(!isData())if(lepType[0]==4 || lepType[1]==4)if(run>186599) //(should already not be data) { _dilWeight->CMXprescale=(_alldilLums[diltype]-_alldilCMXnonprescaled[diltype]+_alldilCMXprescaled[diltype])/_alldilLums[diltype]; //if(debugrun) //std::cout<CMXprescale<CMXprescale=1.0; if(!isData())if(diltype<26 || (diltype>35 && diltype<41))//BMU has raw weight of 1 for now. { rawweight=GetDilWeight(); //if(!isData()&&run>186599)rawweight*=_Dil_Gen6_MC_vs_data_lumscale[diltype]; /*if(_datasource=="Zee" || _datasource=="Zmumu" || _datasource=="Ztautau") if(run < 186599) { if(lepType[0]==7)rawweight*=GetNewDYWeight(lepType[0],run); if(lepType[1]==7)rawweight*=GetNewDYWeight(lepType[1],run); }*/ } //if(run>=222884 && (lepType[0]==4 || lepType[1]==4))rawweight*=_alldilCMXratio[diltype]; if(rawweight>1e2 || rawweight<0 || weight!=weight) //TD get rid of bogus weights. { std::cout<<"bad weight run: "<186599)luminosityweight*=_Dil_Gen6_MC_vs_data_lumscale[diltype]; } weight=rawweight*luminosityweight*gennumberweight; //TD official values that go to the analysis are scaled according to the ratios of the generated events,without any cuts on dilepton mass or primary vertex z0. if(_sexocombined && dilmass<25 && !_sexocomb_nat) { /*double filt=1; if(_datasource=="Zee") filt=0.05074; if(_datasource=="Zmumu") filt=0.02944; if(_datasource=="Ztautau")filt=0.00169;*/ weight*=_genNum/_genNum_sexo; } for(int lep=0; lep=10) { DebugOut("found fake"); weight*=GetFakeRate(run, lepType[lep], lepEt[lep]); if(_debug)std::cout<<"weight is"<=10) { DebugOut("found fake"); weight*=GetFakeRate(run, lepType[lep], lepEt[lep]); if(_debug)std::cout<<"weight is"<35 && diltype<41))//BMU has weight of 1 for now with no error. { double thisrelerror=(_dilWeight->DilWeightError(diltype))/rawweight; weighterror=rawweight*sqrt((weighterror*weighterror/(rawweight*rawweight))+(thisrelerror*thisrelerror));//TD this maybe will need to be updated - I don't think any extra error arrive due to the other scaling factors above, but it will need to be scaled itself. } if(debugrun)_dilWeight->SetDebug(false); } if(weight!=weight) { DebugOut("infinite dilepton weight"); weight=0.0; } DebugOut("ENDOF Weights calculation"); //TD ENDOF Weights calculation ++++++++++++++++++++++++++++++++++++++++++++++++++++++ /*if(passanacuts && (diltype<26 || (_useSCMIO && diltype>35 && diltype<41)))//no BMU in the file dumps - it doesn't pass the analysis cuts. { if(debugrun)std::cout<<"printing to _anafiledump"<Fill(); }*/ //std::cout<35 && diltype<41))//no BMU in the min max weights, because this is set to 1 for all BMU weights. weightmm.mm(weight); int NhepgZ=0; for(int hepgz=0; hepgz 0.0) NhepgZ++;// mostly depricated now. //TD Isolation Checking and Muon Geometry Hist Filling ++++++++++++++++++++++++++++++++++ DebugOut("Isolation Checking and Muon Geometry Hist Filling"); int nonisol=0; int bothnonisol=0; if(diltype<26 || (_useSCMIO && diltype>35 && diltype<41))//no BMU in th isolation and geomety plots for now. { for(int lep=0; lepPassCut() != lepCalIsol[lep]thisisolcut)return; //if(run==168640)std::cout<<"lepton "<thisisolcut || lepTrkIsol[lep]>thisisolcut) { bothnonisol++; }else{ if(_drawhists)HistFill("Isol", lepCalIsol[lep], weight); if(_drawhists)HistFill("BigIsol", lepCalIsol[lep], weight); } //if(bothnonisol>=1) //{ if(_drawhists)HistFill(((_leptonType.Int2String(lepType[lep])) + "_leptonisol_cal").c_str(), lepCalIsol[lep], weight); if(_drawhists)HistFill(((_leptonType.Int2String(lepType[lep])) + "_leptonisol_trk").c_str(), lepTrkIsol[lep], weight); //} if(lepCalIsol[lep]>thisisolcut) { nonisol++; } } }//I hope ENDOF no BMU DebugOut("ENDOF Isolation Checking and Muon Geometry Hist Filling"); //TD ENDOF Isolation Checking and Muon Geometry Hist Filling ++++++++++++++++++++++++++++++++++ // if(nonisol>0) if(debugrun)std::cout<<"10run: "<GetCutAnaCut()->PassUpTo("MissingETMag") && _anaCutSet->GetCutAnaCut()->GetCut("MetMag2")->Getpass() && (diltype<26 || (_useSCMIO && diltype>35 && diltype<41)))//no BMU in the weights, although this is mostly depricated now that I'm doing my own likelihood fits. //_anaCutSet->GetCutAnaCut()->GetCut("dilmassmax")->Getpass()) _tomUnbinnedTree->Fill(); if(_anaCutSet->GetCutAnaCut()->PassUpTo("MissingETMag")&&_badCMXRCot==0 && _badCMXWedge==0 && (diltype<26 || (_useSCMIO && diltype>35 && diltype<41)))//no BMU for now. {if(_saveNN)_descVar2->Fill();} if(bothnonisol==0 && _badCMXRCot==0 && _badCMXWedge==0 && dilmass>16.0) { _zmass_040mass.Fill(weight); /*HistFill("allmass040", dilmass, weight); if(diltype==0){HistFill("TCE_TCEmass040", dilmass, weight);} if(diltype==1){HistFill("TCE_PHXmass040", dilmass, weight);} if(diltype==3){HistFill("PHX_PHXmass040", dilmass, weight);} if(diltype==17){HistFill("CMUP_CMUPmass040", dilmass, weight);} if(diltype==18){HistFill("CMUP_CMUmass040", dilmass, weight);} if(diltype==19){HistFill("CMUP_CMPmass040", dilmass, weight);} if(diltype==20){HistFill("CMUP_CMXmass040", dilmass, weight);} if(diltype==21){HistFill("CMUP_CMIOmass040", dilmass, weight);} if(diltype==22){HistFill("CMX_CMXmass040", dilmass, weight);} if(diltype==23){HistFill("CMX_CMUmass040", dilmass, weight);} if(diltype==24){HistFill("CMX_CMPmass040", dilmass, weight);} if(diltype==25){HistFill("CMX_CMIOmass040", dilmass, weight);} if(diltype==30){HistFill("CMUP_BMUmass040", dilmass, weight);} if(diltype==31){HistFill("CMX_BMUmass040", dilmass, weight);} if(diltype==32){HistFill("BMU_BMUmass040", dilmass, weight);} if(diltype==33){HistFill("BMU_CMUmass040", dilmass, weight);} if(diltype==34){HistFill("BMU_CMPmass040", dilmass, weight);} if(diltype==35){HistFill("BMU_CMIOmass040", dilmass, weight);}*/ if(diltype<=DilType::CMX_CMIO) HistFill(((_dilType.Int2StringDash(diltype)) + "lowdilmass").c_str(), dilmass, weight); } if(debugrun)std::cout<<"dildphi-1: "<GetCutAnaCut()->PassUpTo("dilmassmin") && bothnonisol==0 && dilmass>16)//"MissingETMag") && bothnonisol==0 && dilmass>16)//&& _anaCutSet->GetCutAnaCut()->GetCut("dilmassmax")->Getpass()) { if(_badCMXRCot==0 && _badCMXWedge==0 && (diltype<26 || (_useSCMIO && diltype>35 && diltype<41)))//no BMU for now. { if(!samesign) { _metsigcuts[0]+=weight; //total number before DY cut if(metsig>2.0)_metsigcuts[1]+=weight; //DY cut using our metsig double deansumEt=lepEt[0]+lepEt[1]; int nschichehjet=0; for(int jet=0; jet!=ntightjets; jet++)if(fabs(tjetEtaDet[jet])<2.5)if(tjetEt[jet]>15){deansumEt+=tjetEt[jet]; nschichehjet++;} double deanmetsig=metmag*sqrt(deansumEt); if(deanmetsig>2.0)_metsigcuts[2]+=weight; //DY cut using my version of dean's metsig if((metsig>2.0 || (_NNdiltype==1 && metsig>1.5)) && lepEt[0]>20.0 && lepEt[1]>20.0) { ++(_deancomp_fakenumbers[diltype]); ++_deancomp_metsig[0][3]; _deancomp_metsig[1][3]+=weight; ++_deancomp_metsig[0][(int)_NNdiltype]; _deancomp_metsig[1][(int)_NNdiltype]+=weight; for(int lep=0; lep=10) { double fakerate=GetFakeRate(run, lepType[lep], lepEt[lep]); _deancomp_metsig[2][3]+=fakerate; _deancomp_metsig[2][(int)_NNdiltype]+=fakerate; (_deancomp_fakes[diltype])+=fakerate; } } _metsigcuts[3]+=weight; //DY cut using my version of dean's metsig, 20-20 } if(nschichehjet<2) { double shichehspecialmet=metmag*sin(dPhiMetLJ); if(dPhiMetLJ>(3.142/2))shichehspecialmet=metmag; if(_NNdiltype==1 && shichehspecialmet>15)_metsigcuts[4]+=weight; //DY cut using shicheh's metsig else if(shichehspecialmet>25)_metsigcuts[4]+=weight; //DY cut using shicheh's metsig if(_NNdiltype==1 && shichehspecialmet>15 && dilmass>25)_metsigcuts[5]+=weight; //DY cut using shicheh's metsig && dilmass>25 else if(shichehspecialmet>25 && dilmass>25)_metsigcuts[5]+=weight; //DY cut using shicheh's metsig && dilmass >25 } _specialmet=metmag*sin(dPhiMetLJ); if(dPhiMetLJ>(3.142/2.0))_specialmet=metmag; _specialmetsig=metsig*sin(dPhiMetLJ); if(dPhiMetLJ>(3.142/2.0))_specialmetsig=metsig; if(nschichehjet<2) { HistFill("metsigspec", _specialmetsig, weight); HistFill("metspec", _specialmet, weight); } _extraDYpass=false; if(fabs(_7708Cutrejection)==1 && metsig>2.0)_extraDYpass=true; if(fabs(_7708Cutrejection)==2 && metsig>2.0 && _anaCutSet->GetCutAnaCut()->PassUpTo("MissingETMag"))_extraDYpass=true; if(fabs(_7708Cutrejection)==3 && _NNdiltype==1 && _specialmet>15 && nschichehjet<2)_extraDYpass=true; if(fabs(_7708Cutrejection)==3 && _NNdiltype!=1 && _specialmet>25 && nschichehjet<2)_extraDYpass=true; if(fabs(_7708Cutrejection)==4 && nschichehjet<2) { if(_higgsMass==110 && _specialmetsig>2.5)_extraDYpass=true; if(_higgsMass==120 && _specialmetsig>2.9)_extraDYpass=true; if(_higgsMass==130 && _specialmetsig>3.3)_extraDYpass=true; if(_higgsMass==140 && _specialmetsig>3.7)_extraDYpass=true; if(_higgsMass==150 && _specialmetsig>4.1)_extraDYpass=true; if(_higgsMass==160 && _specialmetsig>4.5)_extraDYpass=true; if(_higgsMass==170 && _specialmetsig>4.625)_extraDYpass=true; if(_higgsMass==180 && _specialmetsig>4.75)_extraDYpass=true; if(_higgsMass==190 && _specialmetsig>4.875)_extraDYpass=true; if(_higgsMass==200 && _specialmetsig>5)_extraDYpass=true; } if(fabs(_7708Cutrejection)==5)_extraDYpass=_anaCutSet->GetCutAnaCut()->GetCut("MissingETMag")->Getpass(); } if(initTMVA && _NNdiltype==0)++_passNNDYcut[0]; if(dilmass!=(*(_cutInterface->dilmass())))std::cout<dilmass())<GetCutAnaCut()->PassUpTo("MissingETMag")) { //if(_removeNNtrain) if(_NNdiltype==0)++_removeNNtrain_counter_0; if(_NNdiltype==1)++_removeNNtrain_counter_1; if(_NNdiltype==2)++_removeNNtrain_counter_2; if(_NNdiltype==0 && _datasource=="higgsww" && _removeNNtrain && _removeNNtrain_counter_0 > 19705)return; //"<" for test events if(_NNdiltype==1 && _datasource=="higgsww" && _removeNNtrain && _removeNNtrain_counter_1 > 43361)return; if(_NNdiltype==2 && _datasource=="higgsww" && _removeNNtrain && _removeNNtrain_counter_2 > 21855)return; //if(_removeNNtrain && _datasource=="higgsww" && _myrand>0.5)return; //#include "AnaHistFillDYDom.cc" if(debugrun)std::cout<<"dildphi: "<120) { _histsHighMllControlNNDYCut.Fill(weight); //#include "AnaHistFillHighMllControlNNDYCut.cc" } if(dilmass>66 && dilmass<116) { _histsZPeakNNDYCut.Fill(weight); //#include "AnaHistFillZPeakNNDYCut.cc" } } if(_drawNNhists4) { if(dilmass<66 && dilmass>16) { _histsLowMllControlNNDYCut.Fill(weight); //#include "AnaHistFillLowMllControlNNDYCut.cc" } } if(_drawNNhists2) { _histsNNDYCut.Fill(weight); //#include "AnaHistFillNNDYCut.cc" if(*(_cutInterface->LepAEt())>60 && *(_cutInterface->LepBEt())>50) { _histsLepEtControlNNDYCut.Fill(weight); //#include "AnaHistFillLepEtControlNNDYCut.cc" } } /*HistFill("NNVar_DYNNcut_LepAEn", *(_cutInterface->LepAEn()),weight); HistFill("NNVar_DYNNcut_LepBEn", *(_cutInterface->LepBEn()),weight); HistFill("NNVar_DYNNcut_dilmass", *(_cutInterface->dilmass()),weight); HistFill("NNVar_DYNNcut_metmag", *(_cutInterface->metmag()),weight); HistFill("NNVar_DYNNcut_addEt", *(_cutInterface->addEt()),weight); HistFill("NNVar_DYNNcut_dPhiMetLJ", *(_cutInterface->dPhiMetLJ()),weight); HistFill("NNVar_DYNNcut_ntightjets", *(_cutInterface->ntightjets()),weight); HistFill("NNVar_DYNNcut_jet1_Et", *(_cutInterface->jet1_Et()),weight); HistFill("NNVar_DYNNcut_jet2_Et", *(_cutInterface->jet2_Et()),weight); HistFill("NNVar_DYNNcut_dildphi", dildphi,weight); HistFill("NNVar_DYNNcut_lepR", _lepR,weight); HistFill("NNVar_DYNNcut_metsig", metsig,weight); HistFill("NNVar_DYNNcut_diltype", _NNdiltype,weight); HistFill("NNVar_DYNNcut_Mt_ll", _Mt_ll,weight); HistFill("NNVar_DYNNcut_Mt_llMet", _Mt_llMet,weight); HistFill("NNVar_DYNNcut_Mt_All", _Mt_All,weight); HistFill("NNVar_DYNNcut_Isr", _Isr,weight); HistFill("NNVar_DYNNcut_DilPhillCorr",_DilPhillCorr,weight);*/ } //TD systematicsi if(_NNdiltype==0) { evaluateTMVA(weight, _cutInterface_JESup, "MVA2_TMlpANN_cut1_JESup_ee", false); evaluateTMVA(weight, _cutInterface_JESdn, "MVA2_TMlpANN_cut1_JESdn_ee", false); evaluateTMVA(weight, _cutInterface_LESup, "MVA2_TMlpANN_cut1_LESup_ee", false); evaluateTMVA(weight, _cutInterface_LESdn, "MVA2_TMlpANN_cut1_LESdn_ee", false); }else if(_NNdiltype==1){ evaluateTMVA(weight, _cutInterface_JESup, "MVA2_TMlpANN_cut1_JESup_emu", false); evaluateTMVA(weight, _cutInterface_JESdn, "MVA2_TMlpANN_cut1_JESdn_emu", false); evaluateTMVA(weight, _cutInterface_LESup, "MVA2_TMlpANN_cut1_LESup_emu", false); evaluateTMVA(weight, _cutInterface_LESdn, "MVA2_TMlpANN_cut1_LESdn_emu", false); }else if(_NNdiltype==2){ evaluateTMVA(weight, _cutInterface_JESup, "MVA2_TMlpANN_cut1_JESup_mumu", false); evaluateTMVA(weight, _cutInterface_JESdn, "MVA2_TMlpANN_cut1_JESdn_mumu", false); evaluateTMVA(weight, _cutInterface_LESup, "MVA2_TMlpANN_cut1_LESup_mumu", false); evaluateTMVA(weight, _cutInterface_LESdn, "MVA2_TMlpANN_cut1_LESdn_mumu", false); } } if(bothnonisol==0 && dilmass>16) { _zmass_fullmass.Fill(weight); /*HistFill("allmassfull", dilmass, weight); if(diltype==0){HistFill("TCE_TCEmassfull", dilmass, weight);} if(diltype==1){HistFill("TCE_PHXmassfull", dilmass, weight);} if(diltype==3){HistFill("PHX_PHXmassfull", dilmass, weight);} if(diltype==17){HistFill("CMUP_CMUPmassfull", dilmass, weight);} if(diltype==18){HistFill("CMUP_CMUmassfull", dilmass, weight);} if(diltype==19){HistFill("CMUP_CMPmassfull", dilmass, weight);} if(diltype==20){HistFill("CMUP_CMXmassfull", dilmass, weight);} if(diltype==21){HistFill("CMUP_CMIOmassfull", dilmass, weight);} if(diltype==22){HistFill("CMX_CMXmassfull", dilmass, weight);} if(diltype==23){HistFill("CMX_CMUmassfull", dilmass, weight);} if(diltype==24){HistFill("CMX_CMPmassfull", dilmass, weight);} if(diltype==25){HistFill("CMX_CMIOmassfull", dilmass, weight);} if(diltype==30){HistFill("CMUP_BMUmassfull", dilmass, weight);} if(diltype==31){HistFill("CMX_BMUmassfull", dilmass, weight);} if(diltype==32){HistFill("BMU_BMUmassfull", dilmass, weight);} if(diltype==33){HistFill("BMU_CMUmassfull", dilmass, weight);} if(diltype==34){HistFill("BMU_CMPmassfull", dilmass, weight);} if(diltype==35){HistFill("BMU_CMIOmassfull", dilmass, weight);} */ for(int lep=0; lep=DilType::trilep && lepType[lep]==LeptonType::BMU)) { if(_drawhists)HistFill(((_leptonType.Int2String(lepType[lep])) + " leptonET").c_str(), lepEt[lep], weight); } } if(dilmass<66) { /* for(int lep=0; lepLepAEn()),weight); HistFill("Rawlowmass_LepBEn", *(_cutInterface->LepBEn()),weight); HistFill("Rawlowmass_dilmass", *(_cutInterface->dilmass()),weight); HistFill("Rawlowmass_metmag", *(_cutInterface->metmag()),weight); HistFill("Rawlowmass_addEt", *(_cutInterface->addEt()),weight); HistFill("Rawlowmass_dPhiMetLJ", *(_cutInterface->dPhiMetLJ()),weight); HistFill("Rawlowmass_ntightjets", *(_cutInterface->ntightjets()),weight); HistFill("Rawlowmass_jet1_Et", *(_cutInterface->jet1_Et()),weight); HistFill("Rawlowmass_jet2_Et", *(_cutInterface->jet2_Et()),weight); HistFill("Rawlowmass_dildphi", dildphi,weight); HistFill("Rawlowmass_lepR", _lepR,weight); HistFill("Rawlowmass_metsig", metsig,weight); HistFill("Rawlowmass_diltype", _NNdiltype,weight); HistFill("Rawlowmass_Mt_ll", _Mt_ll,weight); HistFill("Rawlowmass_Mt_llMet", _Mt_llMet,weight); HistFill("Rawlowmass_Mt_All", _Mt_All,weight); HistFill("Rawlowmass_Isr", _Isr,weight); HistFill("Rawlowmass_DilPhillCorr",_DilPhillCorr,weight);*/ if(_drawhists) { _histsDYDomLowM.Fill(weight); //#include "AnaHistFillDYDomLowM.cc" } }else if(dilmass>120){ /*for(int lep=0; lepLepAEn()),weight); HistFill("Rawhighmass_LepBEn", *(_cutInterface->LepBEn()),weight); HistFill("Rawhighmass_dilmass", *(_cutInterface->dilmass()),weight); HistFill("Rawhighmass_metmag", *(_cutInterface->metmag()),weight); HistFill("Rawhighmass_addEt", *(_cutInterface->addEt()),weight); HistFill("Rawhighmass_dPhiMetLJ", *(_cutInterface->dPhiMetLJ()),weight); HistFill("Rawhighmass_ntightjets", *(_cutInterface->ntightjets()),weight); HistFill("Rawhighmass_jet1_Et", *(_cutInterface->jet1_Et()),weight); HistFill("Rawhighmass_jet2_Et", *(_cutInterface->jet2_Et()),weight); HistFill("Rawhighmass_dildphi", dildphi,weight); HistFill("Rawhighmass_lepR", _lepR,weight); HistFill("Rawhighmass_metsig", metsig,weight); HistFill("Rawhighmass_diltype", _NNdiltype,weight); HistFill("Rawhighmass_Mt_ll", _Mt_ll,weight); HistFill("Rawhighmass_Mt_llMet", _Mt_llMet,weight); HistFill("Rawhighmass_Mt_All", _Mt_All,weight); HistFill("Rawhighmass_Isr", _Isr,weight); HistFill("Rawhighmass_DilPhillCorr",_DilPhillCorr,weight);*/ if(_drawhists){ _histsDYDomHighM.Fill(weight); //#include "AnaHistFillDYDomHighM.cc" } } } if(_drawhists){ _histsDYDom.Fill(weight); //#include "AnaHistFillDYDom.cc" } if(_drawNNhists && initTMVA && _anaCutSet->GetCutAnaCut()->PassUpTo("MissingETMag")) { if(dilmass>120) { _histsHighMllControlNNInputVar.Fill(weight); //#include "AnaHistFillHighMllControlNNInputVar.cc" } if(dilmass>66 && dilmass<116) { _histsZPeakNNInputVar.Fill(weight); //#include "AnaHistFillZPeakNNInputVar.cc" } } if(_drawNNhists4 && initTMVA && _anaCutSet->GetCutAnaCut()->PassUpTo("MissingETMag")) { if(dilmass<66 && dilmass>16) { _histsLowMllControlNNInputVar.Fill(weight); //#include "AnaHistFillLowMllControlNNInputVar.cc" } } if(_drawNNhists5 && initTMVA && _anaCutSet->GetCutAnaCut()->PassUpTo("MissingETMag")) { if(_specialmet>15 || (_NNdiltype==1 && _specialmet>10)) if(_specialmet<25 || (_NNdiltype==1 && _specialmet<15)) if(metmag>25) { _histsLMetHMetSNNInputVar.Fill(weight); //#include "AnaHistFillLMetHMetSNNInputVar.cc" } if(_specialmet>25 || (_NNdiltype==1 && _specialmet>15)) if(metsig<2.5) { _histsLMetSHMetNNInputVar.Fill(weight); //#include "AnaHistFillLMetSHMetNNInputVar.cc" } } if(_drawNNhists2 && initTMVA && _anaCutSet->GetCutAnaCut()->PassUpTo("MissingETMag")) { _histsNNInputVar.Fill(weight); //#include "AnaHistFillNNInputVar.cc" if(ntightjets==3)std::cout<<"three jet events: "<LepAEt())>60 && *(_cutInterface->LepBEt())>50) { _histsLepEtControlNNInputVar.Fill(weight); //#include "AnaHistFillLepEtControlNNInputVar.cc" } } /* if(_drawhists)HistFill("NNVar_LepAEn", *(_cutInterface->LepAEn()),weight); if(_drawhists)HistFill("NNVar_LepBEn", *(_cutInterface->LepBEn()),weight); if(_drawhists)HistFill("NNVar_LepAEt", *(_cutInterface->LepAEt()),weight); if(_NNdiltype==0)if(_drawhists)HistFill("NNVar_LepAEt_ee", *(_cutInterface->LepAEt()),weight); if(_NNdiltype==1)if(_drawhists)HistFill("NNVar_LepAEt_emu", *(_cutInterface->LepAEt()),weight); if(_NNdiltype==2)if(_drawhists)HistFill("NNVar_LepAEt_mumu", *(_cutInterface->LepAEt()),weight); if(_drawhists)HistFill("NNVar_LepBEt", *(_cutInterface->LepBEt()),weight); if(_NNdiltype==0)if(_drawhists)HistFill("NNVar_LepBEt_ee", *(_cutInterface->LepBEt()),weight); if(_NNdiltype==1)if(_drawhists)HistFill("NNVar_LepBEt_emu", *(_cutInterface->LepBEt()),weight); if(_NNdiltype==2)if(_drawhists)HistFill("NNVar_LepBEt_mumu", *(_cutInterface->LepBEt()),weight); if(_drawhists)HistFill("NNVar_dilmass", *(_cutInterface->dilmass()),weight); if(_drawhists)HistFill("NNVar_metmag", *(_cutInterface->metmag()),weight); if(_drawhists)HistFill("NNVar_addEt", *(_cutInterface->addEt()),weight); if(_drawhists)HistFill("NNVar_dPhiMetLJ", *(_cutInterface->dPhiMetLJ()),weight); if(_drawhists)HistFill("NNVar_ntightjets", *(_cutInterface->ntightjets()),weight); if(_drawhists)HistFill("NNVar_jet1_Et", *(_cutInterface->jet1_Et()),weight); if(_drawhists)HistFill("NNVar_jet2_Et", *(_cutInterface->jet2_Et()),weight); if(_drawhists)HistFill("NNVar_dildphi", dildphi,weight); if(_drawhists)HistFill("NNVar_lepR", _lepR,weight); if(_drawhists)HistFill("NNVar_metsig", metsig,weight); if(_drawhists)HistFill("NNVar_diltype", _NNdiltype,weight); if(_drawhists)HistFill("NNVar_Mt_ll", _Mt_ll,weight); if(_drawhists)HistFill("NNVar_Mt_llMet", _Mt_llMet,weight); if(_drawhists)HistFill("NNVar_Mt_All", _Mt_All,weight); if(_drawhists)HistFill("NNVar_Isr", _Isr,weight); if(_drawhists)HistFill("NNVar_DilPhillCorr",_DilPhillCorr,weight);*/ /*if(_NNdiltype==1 || metsig>2.0)//TD _NNdiltype==1 -em (metsig cut on rest) { HistFill("NNVar_MetSigCut_LepAEn", *(_cutInterface->LepAEn()),weight); HistFill("NNVar_MetSigCut_LepBEn", *(_cutInterface->LepBEn()),weight); HistFill("NNVar_MetSigCut_dilmass", *(_cutInterface->dilmass()),weight); HistFill("NNVar_MetSigCut_metmag", *(_cutInterface->metmag()),weight); HistFill("NNVar_MetSigCut_addEt", *(_cutInterface->addEt()),weight); HistFill("NNVar_MetSigCut_dPhiMetLJ", *(_cutInterface->dPhiMetLJ()),weight); HistFill("NNVar_MetSigCut_ntightjets", *(_cutInterface->ntightjets()),weight); HistFill("NNVar_MetSigCut_jet1_Et", *(_cutInterface->jet1_Et()),weight); HistFill("NNVar_MetSigCut_jet2_Et", *(_cutInterface->jet2_Et()),weight); HistFill("NNVar_MetSigCut_dildphi", dildphi,weight); HistFill("NNVar_MetSigCut_lepR", _lepR,weight); HistFill("NNVar_MetSigCut_metsig", metsig,weight); HistFill("NNVar_MetSigCut_diltype", _NNdiltype,weight); HistFill("NNVar_MetSigCut_Mt_ll", _Mt_ll,weight); HistFill("NNVar_MetSigCut_Mt_llMet", _Mt_llMet,weight); HistFill("NNVar_MetSigCut_Mt_All", _Mt_All,weight); HistFill("NNVar_MetSigCut_Isr", _Isr,weight); HistFill("NNVar_MetSigCut_DilPhillCorr",_DilPhillCorr,weight); }*/ ////not enough power for this at the moment if(_datasourceint!=-1) { //if(_myrand<(_lowestlumback/(GetInputEvents()/GetXS()))) //{ if(_saveNN)_descVar->Fill(); if(_SaveRjn)_rootJetNetfile<<*_cutInterface->LepAEn()<<" "<< *_cutInterface->LepBEn()<<" "<< *_cutInterface->dilmass()<<" "<< *_cutInterface->metmag()<<" "<< *_cutInterface->ChargeProduct()<<" "<< *_cutInterface->addEt()<<" "<< *_cutInterface->dPhiMetLJ()<<" "<< *_cutInterface->ntightjets()<<" "<< *_cutInterface->jet1_Et()<<" "<< *_cutInterface->jet2_Et()<<" "<< weight<<" "<35 && diltype<41)))//no BMU for now. //NN Cut Classes { (_allNNdilcuts[diltype])->UnFreeze(); (_allNNdilcuts[diltype])->PassAnaCut(); (_allNNdilcuts[diltype])->PassCumulateCut(); _anaNNCutSet->UnFreeze(); //TD cuts are usually freezed to prevent constsnt recalculation; so we have to unfreeze from last event. _anaNNCutSet->PassAnaCut(); _anaNNCutSet->PassCumulateCut(); _anaNNCutSet->GetCutAnaCut()->FlagNm1(); //TD FlagNm1 does check to see if only one cut was not passed and to flag the cut. if(diltype<=4) { _anaNNCutSetee->UnFreeze(); _anaNNCutSetee->PassAnaCut(); _anaNNCutSetee->PassCumulateCut(); _anaNNCutSetee->GetCutAnaCut()->FlagNm1(); }else if(diltype>=17 && diltype<=25){ _anaNNCutSetmumu->UnFreeze(); _anaNNCutSetmumu->PassAnaCut(); _anaNNCutSetmumu->PassCumulateCut(); _anaNNCutSetmumu->GetCutAnaCut()->FlagNm1(); }else if(diltype<17 && diltype >4){ _anaNNCutSetemu->UnFreeze(); _anaNNCutSetemu->PassAnaCut(); _anaNNCutSetemu->PassCumulateCut(); _anaNNCutSetemu->GetCutAnaCut()->FlagNm1(); } if(run<186599)//TD fill the anacuts for the total in the 0d, 0h, and 0i samples. { _anaNNCutSet0d->UnFreeze(); _anaNNCutSet0d->PassAnaCut(); _anaNNCutSet0d->PassCumulateCut(); _anaNNCutSet0d->FlagNm1(); (_allNNdilcuts_0d[diltype])->UnFreeze(); (_allNNdilcuts_0d[diltype])->PassAnaCut(); (_allNNdilcuts_0d[diltype])->PassCumulateCut(); }else if(run<= 203799&& run>186599){ _anaNNCutSet0h->UnFreeze(); _anaNNCutSet0h->PassAnaCut(); _anaNNCutSet0h->PassCumulateCut(); _anaNNCutSet0h->FlagNm1(); (_allNNdilcuts_0h[diltype])->UnFreeze(); (_allNNdilcuts_0h[diltype])->PassAnaCut(); (_allNNdilcuts_0h[diltype])->PassCumulateCut(); }else if(run< 212133&& run>203799){ _anaNNCutSet0i->UnFreeze(); _anaNNCutSet0i->PassAnaCut(); _anaNNCutSet0i->PassCumulateCut(); _anaNNCutSet0i->FlagNm1(); (_allNNdilcuts_0i[diltype])->UnFreeze(); (_allNNdilcuts_0i[diltype])->PassAnaCut(); (_allNNdilcuts_0i[diltype])->PassCumulateCut(); } if(run< 212133&& run >186599) { _anaNNCutSet0h0i->UnFreeze(); _anaNNCutSet0h0i->PassAnaCut(); _anaNNCutSet0h0i->PassCumulateCut(); _anaNNCutSet0h0i->FlagNm1(); (_allNNdilcuts_0h0i[diltype])->UnFreeze(); (_allNNdilcuts_0h0i[diltype])->PassAnaCut(); (_allNNdilcuts_0h0i[diltype])->PassCumulateCut(); } } DebugOut(" ENDOF Tree Filling for NN and Tom"); //TD ENDOF Tree Filling for NN and Tom ++++++++++++++++++++++++++++++++++++++++++++++++++++ //TD Lepton Et filling +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ if(diltype<26 || (_useSCMIO && diltype>35 && diltype<41))//no BMU { if(_drawhists)HistFill("Lepton1Et",*(_cutInterface->LepAEn()), weight); if(_drawhists)HistFill("Lepton2Et",*(_cutInterface->LepBEn()), weight); } /* if(bothnonisol==0 && dilmass>16) { //if(_datasource=="data")if(diltype==DilType::CMX_CMP)filedump<=DilType::trilep && lepType[lep]==LeptonType::BMU)) HistFill(((_leptonType.Int2StringDash(lepType[lep])) + " leptonET").c_str(), lepEt[lep], weight); //only include the normal muons in plots, as if BMU dileptons get in, this screws up the luminosity for the plot. //if(_datasource=="data")std::cout<<((_leptonType.Int2StringDash(lepType[lep])) + " leptonET").c_str()<34)//no BMU incase the BMU energy calculation screws up the missing et if(_drawhists)HistFill("Missing_Et",*(_cutInterface->metmag()), weight); //std::cout<<_anaCutSet->GetCutAnaCut() //TD Analysis NM1 Style hist filling ++++++++++++++++++++++++++++++++++++++++++++++++++++ if(diltype<26 || (_useSCMIO && diltype>35 && diltype<41))//no BMU in any analysis type plots { if(_anaCutSet->GetCutAnaCut()->PassUpTo("CominedJetNumbers")) //Plots before Jet Cut { HistFill("JetNumBeforeCut",*(_cutInterface->ntightjets()), weight); if(_NNdiltype==0)if(_drawhists)HistFill("JetNumBeforeCut_ee",*(_cutInterface->ntightjets()), weight); if(_NNdiltype==1)if(_drawhists)HistFill("JetNumBeforeCut_emu",*(_cutInterface->ntightjets()), weight); if(_NNdiltype==2)if(_drawhists)HistFill("JetNumBeforeCut_mumu",*(_cutInterface->ntightjets()), weight); if(*(_cutInterface->ntightjets())>0) { HistFill("LeadJetEt_anyN",*(_cutInterface->jet1_Et()), weight); if(_NNdiltype==0)if(_drawhists)HistFill("LeadJetEt_anyN_ee",*(_cutInterface->jet1_Et()), weight); if(_NNdiltype==1)if(_drawhists)HistFill("LeadJetEt_anyN_emu",*(_cutInterface->jet1_Et()), weight); if(_NNdiltype==2)if(_drawhists)HistFill("LeadJetEt_anyN_mumu",*(_cutInterface->jet1_Et()), weight); } if(*(_cutInterface->ntightjets())==1) { HistFill("LeadJetEt_1Jet",*(_cutInterface->jet1_Et()), weight); if(_NNdiltype==0)if(_drawhists)HistFill("LeadJetEt_1Jet_ee",*(_cutInterface->jet1_Et()), weight); if(_NNdiltype==1)if(_drawhists)HistFill("LeadJetEt_1Jet_emu",*(_cutInterface->jet1_Et()), weight); if(_NNdiltype==2)if(_drawhists)HistFill("LeadJetEt_1Jet_mumu",*(_cutInterface->jet1_Et()), weight); } if(*(_cutInterface->ntightjets())==2) { HistFill("LeadJetEt_2Jet",*(_cutInterface->jet1_Et()), weight); if(_NNdiltype==0)if(_drawhists)HistFill("LeadJetEt_2Jet_ee",*(_cutInterface->jet1_Et()), weight); if(_NNdiltype==1)if(_drawhists)HistFill("LeadJetEt_2Jet_emu",*(_cutInterface->jet1_Et()), weight); if(_NNdiltype==2)if(_drawhists)HistFill("LeadJetEt_2Jet_mumu",*(_cutInterface->jet1_Et()), weight); HistFill("SecondJetEt_2Jet",*(_cutInterface->jet2_Et()), weight); if(_NNdiltype==0)if(_drawhists)HistFill("SecondJetEt_2Jet_ee",*(_cutInterface->jet2_Et()), weight); if(_NNdiltype==1)if(_drawhists)HistFill("SecondJetEt_2Jet_emu",*(_cutInterface->jet2_Et()), weight); if(_NNdiltype==2)if(_drawhists)HistFill("SecondJetEt_2Jet_mumu",*(_cutInterface->jet2_Et()), weight); } } //weight=1; //_passEtcut[0]+=weight; //denominator for the MissingETMag Cut efficirency //TD should this be here? //std::cout<<"*(_cutInterface->metmag()*(_cutInterface->metmag()"<<*(_cutInterface->metmag())<metmag())>20.0)_passEtcut[1]+=weight; //if(*(_cutInterface->metmag())>30.0)_passEtcut[2]+=weight; //if(*(_cutInterface->metmag())>40.0)_passEtcut[3]+=weight; if(_anaCutSet->GetCutAnaCut()->PassUpTo("MissingETMag")) //Plots before Et Cut { _passEtcut[0]+=weight; //denominator for the MissingETMag Cut efficirency HistFill("MissingETMag",*(_cutInterface->metmag()), weight); if(_NNdiltype==0)if(_drawhists)HistFill("MissingETMag_ee",*(_cutInterface->metmag()), weight); if(_NNdiltype==1)if(_drawhists)HistFill("MissingETMag_emu",*(_cutInterface->metmag()), weight); if(_NNdiltype==2)if(_drawhists)HistFill("MissingETMag_mumu",*(_cutInterface->metmag()), weight); //if(_anaCutSet->GetCutAnaCut()->GetCut("MissingETMag")->Getpass()) //{ if(*(_cutInterface->metmag())>40.0)_passEtcut[3]+=weight; else if(*(_cutInterface->metmag())>30.0)_passEtcut[2]+=weight; else if(*(_cutInterface->metmag())>20.0)_passEtcut[1]+=weight; //if(*(_cutInterface->metmag())>30.0)_passEtcut[2]+=weight; // if(*(_cutInterface->metmag())>40.0)_passEtcut[3]+=weight; //} } if(_anaCutSet->GetCutAnaCut()->PassUpTo("dilmassmax")) //Plots before second dilmass Cut { if(_drawhists){ _histsWWDom.Fill(weight); //#include "AnaHistFillWWDom.cc" } HistFill("dilmassmax",*(_cutInterface->dilmass()), weight); if(_NNdiltype==0)if(_drawhists)HistFill("dilmassmax_ee",*(_cutInterface->dilmass()), weight); if(_NNdiltype==1)if(_drawhists)HistFill("dilmassmax_emu",*(_cutInterface->dilmass()), weight); if(_NNdiltype==2)if(_drawhists)HistFill("dilmassmax_mumu",*(_cutInterface->dilmass()), weight); if(dilmass<80 && dilmass>60) { if(_drawhists){ _histsWWDomMBox.Fill(weight); //#include "AnaHistFillWWDomMBox.cc" } /*HistFill("dilmassbox_run", run, weight); HistFill("dilmassbox_evt", evt, weight); for(int lep=0; lep2) { if(_drawhists)HistFill("dilmassbox_DRbox_dildphi", dildphi, weight); //checkout the dilphi in the dR excess seen in the box if(_drawhists)HistFill("dilmassbox_DRbox_dPhiMetLJ",*(_cutInterface->dPhiMetLJ()), weight); if(_drawhists)HistFill("dilmassbox_DRbox_lepetass", lepEt[0]-lepEt[1]/lepEt[0]+lepEt[1], weight); if(_isdata)std::cout<<"suspect event; run, evt: "<40){ if(_drawhists){ _histsWWDomOutMBox.Fill(weight); //#include "AnaHistFillWWDomOutMBox.cc" } /*HistFill("outdilmassbox_run", run, weight); HistFill("outdilmassbox_evt", evt, weight); for(int lep=0; lepGetCutAnaCut()->PassUpTo("TotalEt")) //Plots before TotalEt { HistFill("TotalEt",*(_cutInterface->addEt()), weight); if(_NNdiltype==0)if(_drawhists)HistFill("TotalEt_ee",*(_cutInterface->addEt()), weight); if(_NNdiltype==1)if(_drawhists)HistFill("TotalEt_emu",*(_cutInterface->addEt()), weight); if(_NNdiltype==2)if(_drawhists)HistFill("TotalEt_mumu",*(_cutInterface->addEt()), weight); } //N-1 plots if(_anaCutSet->GetCutAnaCut()->GetCut("CominedJetNumbers")->Nm1()) //Jet N-1 Cut { if(_drawhists)HistFill("Nm1JetNumBeforeCut",*(_cutInterface->ntightjets()), weight); if(*(_cutInterface->ntightjets())>0) if(_drawhists)HistFill("Nm1LeadJetEt_anyN",*(_cutInterface->jet1_Et()), weight); if(*(_cutInterface->ntightjets())==1) { if(_drawhists)HistFill("Nm1LeadJetEt_1Jet",*(_cutInterface->jet1_Et()), weight); } if(*(_cutInterface->ntightjets())==2) { if(_drawhists)HistFill("Nm1LeadJetEt_2Jet",*(_cutInterface->jet1_Et()), weight); if(_drawhists)HistFill("Nm1SecondJetEt_2Jet",*(_cutInterface->jet2_Et()), weight); } } if(_anaCutSet->GetCutAnaCut()->GetCut("MissingETMag")->Nm1()) //N-1 Et Cut { // _anaCutSet->GetCutAnaCut()->PrintCuts(); if(_drawhists)HistFill("Nm1MissingETMag",*(_cutInterface->metmag()), weight); if(_NNdiltype==0) { if(_drawhists)HistFill("Nm1Metee_LepAEn", *(_cutInterface->LepAEn()),weight); if(_drawhists)HistFill("Nm1Metee_LepBEn", *(_cutInterface->LepBEn()),weight); if(_drawhists)HistFill("Nm1Metee_dilmass", *(_cutInterface->dilmass()),weight); if(_drawhists)HistFill("Nm1Metee_metmag", *(_cutInterface->metmag()),weight); if(_drawhists)HistFill("Nm1Metee_addEt", *(_cutInterface->addEt()),weight); if(_drawhists)HistFill("Nm1Metee_dPhiMetLJ", *(_cutInterface->dPhiMetLJ()),weight); if(_drawhists)HistFill("Nm1Metee_ntightjets", *(_cutInterface->ntightjets()),weight); if(_drawhists)HistFill("Nm1Metee_jet1_Et", *(_cutInterface->jet1_Et()),weight); if(_drawhists)HistFill("Nm1Metee_jet2_Et", *(_cutInterface->jet2_Et()),weight); if(_drawhists)HistFill("Nm1Metee_dildphi", dildphi,weight); if(_drawhists)HistFill("Nm1Metee_lepR", _lepR,weight); if(_drawhists)HistFill("Nm1Metee_metsig", metsig,weight); } if(_NNdiltype==1) { if(_drawhists)HistFill("Nm1Metemu_LepAEn", *(_cutInterface->LepAEn()),weight); if(_drawhists)HistFill("Nm1Metemu_LepBEn", *(_cutInterface->LepBEn()),weight); if(_drawhists)HistFill("Nm1Metemu_dilmass", *(_cutInterface->dilmass()),weight); if(_drawhists)HistFill("Nm1Metemu_metmag", *(_cutInterface->metmag()),weight); if(_drawhists)HistFill("Nm1Metemu_addEt", *(_cutInterface->addEt()),weight); if(_drawhists)HistFill("Nm1Metemu_dPhiMetLJ", *(_cutInterface->dPhiMetLJ()),weight); if(_drawhists)HistFill("Nm1Metemu_ntightjets", *(_cutInterface->ntightjets()),weight); if(_drawhists)HistFill("Nm1Metemu_jet1_Et", *(_cutInterface->jet1_Et()),weight); if(_drawhists)HistFill("Nm1Metemu_jet2_Et", *(_cutInterface->jet2_Et()),weight); if(_drawhists)HistFill("Nm1Metemu_dildphi", dildphi,weight); if(_drawhists)HistFill("Nm1Metemu_lepR", _lepR,weight); if(_drawhists)HistFill("Nm1Metemu_metsig", metsig,weight); } if(_NNdiltype==2) { if(_drawhists)HistFill("Nm1Metmumu_LepAEn", *(_cutInterface->LepAEn()),weight); if(_drawhists)HistFill("Nm1Metmumu_LepBEn", *(_cutInterface->LepBEn()),weight); if(_drawhists)HistFill("Nm1Metmumu_dilmass", *(_cutInterface->dilmass()),weight); if(_drawhists)HistFill("Nm1Metmumu_metmag", *(_cutInterface->metmag()),weight); if(_drawhists)HistFill("Nm1Metmumu_addEt", *(_cutInterface->addEt()),weight); if(_drawhists)HistFill("Nm1Metmumu_dPhiMetLJ", *(_cutInterface->dPhiMetLJ()),weight); if(_drawhists)HistFill("Nm1Metmumu_ntightjets", *(_cutInterface->ntightjets()),weight); if(_drawhists)HistFill("Nm1Metmumu_jet1_Et", *(_cutInterface->jet1_Et()),weight); if(_drawhists)HistFill("Nm1Metmumu_jet2_Et", *(_cutInterface->jet2_Et()),weight); if(_drawhists)HistFill("Nm1Metmumu_dildphi", dildphi,weight); if(_drawhists)HistFill("Nm1Metmumu_lepR", _lepR,weight); if(_drawhists)HistFill("Nm1Metmumu_metsig", metsig,weight); } } if(_anaCutSet->GetCutAnaCut()->GetCut("dilmassmax")->Nm1()) //N-1 dilmass Cut { if(_drawhists)HistFill("Nm1dilmassmax",*(_cutInterface->dilmass()), weight); } if(_anaCutSet->GetCutAnaCut()->GetCut("TotalEt")->Nm1()) //N-1TotalEt { if(_drawhists)HistFill("Nm1TotalEt",*(_cutInterface->addEt()), weight); } if(_anaCutSet->GetCutAnaCut()->GetCut("SameSign")->Nm1()) { if(_isdata)std::cout<<"same sign Nm1 run: "<LepAEn()),weight); if(_drawhists)HistFill("PassSameSign_LepBEn", *(_cutInterface->LepBEn()),weight); if(_drawhists)HistFill("PassSameSign_dilmass", *(_cutInterface->dilmass()),weight); if(_drawhists)HistFill("PassSameSign_metmag", *(_cutInterface->metmag()),weight); if(_drawhists)HistFill("PassSameSign_addEt", *(_cutInterface->addEt()),weight); if(_drawhists)HistFill("PassSameSign_dPhiMetLJ", *(_cutInterface->dPhiMetLJ()),weight); if(_drawhists)HistFill("PassSameSign_ntightjets", *(_cutInterface->ntightjets()),weight); if(_drawhists)HistFill("PassSameSign_jet1_Et", *(_cutInterface->jet1_Et()),weight); if(_drawhists)HistFill("PassSameSign_jet2_Et", *(_cutInterface->jet2_Et()),weight); if(_drawhists)HistFill("PassSameSign_dildphi", dildphi,weight); if(_drawhists)HistFill("PassSameSign_lepR", _lepR,weight); if(_drawhists)HistFill("PassSameSign_metsig", metsig,weight); } }//ENDOF no BMU in NM1 plots //TD ENDOF Analysis NM1 Style hist filling ++++++++++++++++++++++++++++++++++++++++++++++++++++ if(diltype<26 || (_useSCMIO && diltype>35 && diltype<41))//no BMU in the following small calculations { if(samesign)if(_drawhists)HistFill("SameSignDilMass", dilmass, weight); maxweight = TMath::Max((double)maxweight,(double)dilweight); dilweightmm.mm((double)weight); if(debugrun)_anaCutSet->GetCutAnaCut()->PrintCuts(); if(debugrun)std::cout<<"ettot: "<<*(_cutInterface->addEt())<0) if(_drawhists)HistFill("ZDileptonMassTCEPHX_2010_nonisol", dilmass, weight); if(diltype==1 && goodlep==2 ) if(_drawhists)HistFill("ZDileptonMassTCEPHX_2020_nonisol", dilmass, weight); if(diltype==1 && gooddilep>0 && bothnonisol==0)if(_drawhists)HistFill("ZDileptonMassTCEPHX_2010_isol", dilmass, weight); if(diltype==1 && goodlep==2 && bothnonisol==0)if(_drawhists)HistFill("ZDileptonMassTCEPHX_2020_isol", dilmass, weight); //if(_anaCutSet->GetCutAnaCut()->PassUpTo("dilmassmin")) //{ if(debugrun)std::cout<<" dilmassmin run: "<66 && gooddilep>0 && bothnonisol==0 && _badCMXWedge==0) { if(debugrun)std::cout<<"(dilmass<116 && dilmass>66) run: "<35 && diltype<41))//no BMU in the Z events, incase it screws up that calculation, although, I cannot see how at the moment, this is a precaution. { _thisZevents+=(rawweight*luminosityweight); _totZevents+=(rawweight*luminosityweight); Zinwindow++; } _alldilGoodZ[diltype]+=(rawweight*luminosityweight); _nevents_for_vtxcalc++; _total_vtx_corr+=GetEpsVtx(run); if(_drawhists)_zmass_mass.Fill(weight); /*if(diltype==0){if(_drawhists)HistFill("TCE_TCEmass", dilmass, weight);} if(diltype==1){if(_drawhists)HistFill("TCE_PHXmass", dilmass, weight);} if(diltype==3){if(_drawhists)HistFill("PHX_PHXmass", dilmass, weight);} if(diltype==17){if(_drawhists)HistFill("CMUP_CMUPmass", dilmass, weight);} if(diltype==18){if(_drawhists)HistFill("CMUP_CMUmass", dilmass, weight);} if(diltype==19){if(_drawhists)HistFill("CMUP_CMPmass", dilmass, weight);} if(diltype==20){if(_drawhists)HistFill("CMUP_CMXmass", dilmass, weight);} if(diltype==21){if(_drawhists)HistFill("CMUP_CMIOmass", dilmass, weight);} if(diltype==22){if(_drawhists)HistFill("CMX_CMXmass", dilmass, weight);} if(diltype==23){if(_drawhists)HistFill("CMX_CMUmass", dilmass, weight);} if(diltype==24){if(_drawhists)HistFill("CMX_CMPmass", dilmass, weight);} if(diltype==25){if(_drawhists)HistFill("CMX_CMIOmass", dilmass, weight);} if(diltype==30){if(_drawhists)HistFill("CMUP_BMUmass", dilmass, weight);} if(diltype==31){if(_drawhists)HistFill("CMX_BMUmass", dilmass, weight);} if(diltype==32){if(_drawhists)HistFill("BMU_BMUmass", dilmass, weight);} if(diltype==33){if(_drawhists)HistFill("BMU_CMUmass", dilmass, weight);} if(diltype==34){if(_drawhists)HistFill("BMU_CMPmass", dilmass, weight);} if(diltype==35){if(_drawhists)HistFill("BMU_CMIOmass", dilmass, weight);} */ // _alldilSS.push_back(0); }else{ //include for same sign in equations. if(debugrun)std::cout<<"(dilmass<116 && dilmass>66) samesign run: "<35 && diltype<41))HistFill("Weight", (rawweight*luminosityweight), 1); if(diltype<26 || (_useSCMIO && diltype>35 && diltype<41))HistFill("WeightError", (weighterror*luminosityweight), 1); //TD errors for Z xs only! they are in that loop! this loop, I mean! // HistFill("RelWeightError", (rawweight*luminosityweight), 1); }else{if(debugrun)std::cout<<"notxs: mass: "<66 && goodlep==2 && nonisol==0 && _badCMXRCot==0 && _badCMXWedge==0)//TD my set of cuts for Z crossections { //bool mylepet=true; //for(int lep=0; lep66 && dilep1020==1 && bothnonisol==0) { if(!samesign) //include for same sign in equations. { //include for same sign in equations. _alldilGoodZ_1020cut[diltype]+=(rawweight*luminosityweight); } } //ENDOF TD Z XS Calculations +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ //TD dilDphi histogram filling++++++++++++++++++++++++++++++++++++++++++++++++++++++++ if(diltype<26)//TD sort this out - if _useSCMIO, e-mu pairs get into mumu..// || (_useSCMIO && diltype>35 && diltype<41))//no BMU here either { if(passanacuts && _badCMXWedge==0) { if(_datasource=="data")std::cout<<"Passed: run "<LepAEn()),weight); if(_drawhists)HistFill("PassAnaCut_LepBEn", *(_cutInterface->LepBEn()),weight); if(_drawhists)HistFill("PassAnaCut_dilmass", *(_cutInterface->dilmass()),weight); if(_drawhists)HistFill("PassAnaCut_metmag", *(_cutInterface->metmag()),weight); if(_drawhists)HistFill("PassAnaCut_addEt", *(_cutInterface->addEt()),weight); if(_drawhists)HistFill("PassAnaCut_dPhiMetLJ", *(_cutInterface->dPhiMetLJ()),weight); if(_drawhists)HistFill("PassAnaCut_ntightjets", *(_cutInterface->ntightjets()),weight); if(_drawhists)HistFill("PassAnaCut_jet1_Et", *(_cutInterface->jet1_Et()),weight); if(_drawhists)HistFill("PassAnaCut_jet2_Et", *(_cutInterface->jet2_Et()),weight); if(_drawhists)HistFill("PassAnaCut_dildphi", dildphi,weight); if(_drawhists)HistFill("PassAnaCut_lepR", _lepR,weight); if(_drawhists)HistFill("PassAnaCut_metsig", metsig,weight); if(_drawhists){ _histsHWWDom.Fill(weight); //#include "AnaHistFillHWWDom.cc" } for(int lep=0; lep=17){ if(_isdata)std::cout<<"filled in mumu"<PassAnaCut() && _badCMXWedge==0)//TD does it pass the high JES cuts? { //TD separate events into ee emu and mumu HistFill("dilDphi_JESup",dildphi, weight); if(diltype<=4) { HistFill("dilDphiee_JESup",dildphi, weight); }else if(diltype>=17){ HistFill("dilDphimumu_JESup",dildphi, weight); }else{ HistFill("dilDphiemu_JESup",dildphi, weight); } } if(_anaCutSet_JESdn->PassAnaCut() && _badCMXWedge==0)//TD does it pass the low JES cuts? { //TD separate events into ee emu and mumu HistFill("dilDphi_JESdn",dildphi, weight); if(diltype<=4) { HistFill("dilDphiee_JESdn",dildphi, weight); }else if(diltype>=17){ HistFill("dilDphimumu_JESdn",dildphi, weight); }else{ HistFill("dilDphiemu_JESdn",dildphi, weight); } } if(_anaCutSet_LESup->PassAnaCut() && _badCMXWedge==0)//TD does it pass the high LES cuts? { //TD separate events into ee emu and mumu HistFill("dilDphi_LESup",dildphi, weight); if(diltype<=4) { HistFill("dilDphiee_LESup",dildphi, weight); }else if(diltype>=17){ HistFill("dilDphimumu_LESup",dildphi, weight); }else{ HistFill("dilDphiemu_LESup",dildphi, weight); } } if(_anaCutSet_LESdn->PassAnaCut() && _badCMXWedge==0)//TD does it pass the low LES cuts? { //TD separate events into ee emu and mumu HistFill("dilDphi_LESdn",dildphi, weight); if(diltype<=4) { HistFill("dilDphiee_LESdn",dildphi, weight); }else if(diltype>=17){ HistFill("dilDphimumu_LESdn",dildphi, weight); }else{ HistFill("dilDphiemu_LESdn",dildphi, weight); } } //ENDOF TD dilDphi histogram filling++++++++++++++++++++++++++++++++++++++++++++++++++++++++ }//end of no BMU here either if(!samesign)//TD depricated Z number storage. need to be put in the right places. Mass plots too! { if(diltype==1)if(_drawhists)HistFill("ZDileptonMassTCEPHX",dilmass, weight); if(diltype==1)if(_drawhists)HistFill("ZDileptonMassTCEPHX_sml",dilmass, weight); HistFill("DileptonMass", dilmass, weight); HistFill("ZDileptonMass", dilmass, weight); (*(_dileptonmasshists.GetAnaHistVector()))[diltype]->GetHist()->Fill(dilmass, weight);//for Z mass. } //WW crossec stuff ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ if(diltype<26 || (_useSCMIO && diltype>35 && diltype<41))//no BMU here { if(!samesign) { int bigjet=0; if(dilmass>16) if(bothnonisol==0) if(_badCMXWedge==0) if(((dilmass<60 || dilmass>120) && metmag>25) || (dilmass>60 && dilmass<120 && metmag>40)) if(metsig>5.5) { for(int jet=0; jet!=ntightjets; jet++)if(fabs(tjetEtaDet[jet])<2.5)if(tjetEt[jet]>20)bigjet++; if(bigjet<=1 && goodlep==2) { if(_drawhists)HistFill("WWmetsig", metsig, weight); if(_drawhists)HistFill("WWdilmass", dilmass, weight); HistFill("WWmetmag", metmag, weight); if(_NNdiltype==0) { HistFill("WWmetmag_ee", metmag, weight); }else if(_NNdiltype==1){ HistFill("WWmetmag_emu", metmag, weight); }else if(_NNdiltype==2){ HistFill("WWmetmag_mumu", metmag, weight); } if(_drawhists)HistFill("WWsumEt", sumEt, weight); for(int lep=0; lep16) if(bothnonisol==0) if(_badCMXWedge==0) if(metmag>25) if(metmag<50 ||(metmag>50 && dPhiMetLJ>(PI/9.0))) { if(7615 && fabs(tjetEtaDet[jet])<2.5)Frankbigjet++; if(Frankbigjet==0) { HistFill("FrankWWmetmag", metmag, weight); if(_NNdiltype==0) { HistFill("FrankWWmetmag_ee", metmag, weight); }else if(_NNdiltype==1){ HistFill("FrankWWmetmag_emu", metmag, weight); }else if(_NNdiltype==2){ HistFill("FrankWWmetmag_mumu", metmag, weight); } } } } //ENDOF WW crossec stuff ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ if(_datasource=="higgsww" && _matTest > 0) { TDMatrix test; TLorentzVector lep1(lepPx[0], lepPy[0], lepPz[0], lepEn[0]); TLorentzVector lep2(lepPx[1], lepPy[1], lepPz[1], lepEn[1]); test.scanmasses(lep1, lep2, (TH1F*)(_subAnaHists->GetAnaHist("MatrixTest")->GetHist()), 30, 160, 220, 10000); _matTest--; } }//end of no BMU here /*if(_datasource=="WZ" || _datasource=="Zee") { if(_badCMXWedge==0) { if(_anaCutSet_LESup->PassAnaCut() || passanacuts) { _anaCutSet->GetCutAnaCut()->PrintCuts(); _anaCutSet_LESup->GetCutAnaCut()->PrintCuts(); std::cout<<"jet numbers LESup"<<*(_cutInterface_LESup->nmjets())<<" "<<*(_cutInterface_LESup->nljets())<<" "<<*(_cutInterface_LESup->nhjets())<nmjets())<<" "<<*(_cutInterface->nljets())<<" "<<*(_cutInterface->nhjets())<HistSetEmpty()) { _subAnaHists->AddAnaHist(new TDAnaHist("DileptonMass", "dilepton masses for Z peak", 66.0, 116.0, 120, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("ZDileptonMass", "dilepton masses for Z peak", 0.0, 120.0, 120, _datasource.c_str(), "HistSetDesc")); if(_drawhists) { _subAnaHists->AddAnaHist(new TDAnaHist("ZDileptonMassTCEPHX", "dilepton masses for TCE-PHX Z peak", 0.0, 120.0, 120, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("ZDileptonMassTCEPHX_sml", "dilepton masses for TCE-PHX Z peak",66.0, 116.0, 120, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("HepGZDileptonMass", "hepg dilepton masses for Z peak", 66.0, 116.0, 120, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("SameSignDilMass", "same sign dilepton masses", 66.0, 116.0, 120, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("ZDileptonMassTCEPHX_2020_nonisol", "dilepton masses for TCE-PHX Z peak_2020_nonisol", 66.0, 116.0, 120, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("ZDileptonMassTCEPHX_2010_nonisol", "dilepton masses for TCE-PHX Z peak_2010_nonisol", 66.0, 116.0, 120, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("ZDileptonMassTCEPHX_2010_isol", "dilepton masses for TCE-PHX Z peak_2010_isol", 66.0, 116.0, 120, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("ZDileptonMassTCEPHX_2020_isol", "dilepton masses for TCE-PHX Z peak_2020_isol", 66.0, 116.0, 120, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("ZDileptonMassTCEPHX_nonisol", "dilepton masses for TCE-PHX Z peak_nonisol", 66.0, 116.0, 120, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("Isolbefore", "before lepton calorimeter isolation cut", 0.0, 0.2, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("Isol", "after lepton calorimeter isolation cut", 0.0, 0.2, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BigIsolbefore", "before lepton calorimeter isolation cut", 0.0, 1.4, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BigIsol", "after lepton calorimeter isolation cut", 0.0, 1.4, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BigIsolTCE", "TCE Trk Isolation", 0.0, 1.4, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BigIsolCMUP", "CMUP Trk Isolation", 0.0, 1.4, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BigIsolCMX", "CMX Trk Isolation", 0.0, 1.4, 100, _datasource.c_str(), "HistSetDesc")); //_subAnaHists->AddAnaHist(new TDAnaHist("TrackZ0", "Track z0", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); //_subAnaHists->AddAnaHist(new TDAnaHist("Z0", "z0", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); } _subAnaHists->AddAnaHist(new TDAnaHist("dilDphi", "lepton angular separation", 0.0, 3.141592654, 8, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("dilDphi")->SetAxisLables("Rads","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphilike", ("dildphi in "+ _dilset.GetDilString()+"for like").c_str(), 0.0, 3.141592654, 200, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiee", "lepton angular separation of electrons", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("dilDphiee")->SetAxisLables("Rads","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiemu", "lepton angular separation of muon and electron", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("dilDphiemu")->SetAxisLables("Rads","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphimumu", "lepton angular separation of muons", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("dilDphimumu")->SetAxisLables("Rads","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("TomdilDphi", "lepton angular separation", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("TomdilDphi")->SetAxisLables("Rads","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphi7708", ("dildphi in "+ _dilset.GetDilString()).c_str(), 0.0, 3.141592654, 20, _datasource.c_str(), "HistSetDesc")); //TD histograms corresponding to the dilDphiemu etc. above with high and low JES. _subAnaHists->AddAnaHist(new TDAnaHist("dilDphi_JESup", "dphi, high JES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphi_JESdn", "dphi, low JES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiee_JESup", "dphi of electrons, high JES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiee_JESdn", "dphi of electrons, low JES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiemu_JESup", "dphi of electron and muon, high JES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiemu_JESdn", "dphi of electron and muon, low JES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphimumu_JESup", "dphi of muons, high JES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphimumu_JESdn", "dphi of muons, low JES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); //TD histograms corresponding to the dilDphiemu etc. above with high and low LES. _subAnaHists->AddAnaHist(new TDAnaHist("dilDphi_LESup", "dphi, high LES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphi_LESdn", "dphi, low LES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiee_LESup", "dphi of electrons, high LES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiee_LESdn", "dphi of electrons, low LES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiemu_LESup", "dphi of electron and muon, high LES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiemu_LESdn", "dphi of electron and muon, low LES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphimumu_LESup", "dphi of muons, high LES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphimumu_LESdn", "dphi of muons, low LES", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); //TD Lepton ID weight errors for the three channels: _subAnaHists->AddAnaHist(new TDAnaHist("RelWeightError_ee", "Relative Weights Error for electrons", 0.0, 0.1, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("RelWeightError_emu", "Relative Weights Error for electron and muon", 0.0, 0.1, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("RelWeightError_mumu", "Relative Weights Error for muons", 0.0, 0.1, 100, _datasource.c_str(), "HistSetDesc")); //TD histograms corresponding to the dilDphiemu etc. above with high and low PDF Errors //TD wait for implementation (boom boom). _subAnaHists->AddAnaHist(new TDAnaHist("dilDphi_PDF", "dphi, PDFs", 0.0, 3.141592654, 10, 0, 41, 41, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiee_PDF", "dphi of electrons, PDFs", 0.0, 3.141592654, 10, 0, 41, 41, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiemu_PDF", "dphi of electron and muon, PDFs", 0.0, 3.141592654, 10, 0, 41, 41, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphimumu_PDF", "dphi of muons, PDFs", 0.0, 3.141592654, 10, 0, 41, 41, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphi_PDFup", "dphi, high PDF", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphi_PDFdn", "dphi, low PDF", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiee_PDFup", "dphi of electrons, high PDF", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiee_PDFdn", "dphi of electrons, low PDF", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiemu_PDFup", "dphi of electron and muon, high PDF", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiemu_PDFdn", "dphi of electron and muon, low PDF", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphimumu_PDFup", "dphi of muons, high PDF", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphimumu_PDFdn", "dphi of muons, low PDF", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); //TD histograms corresponding to the dilDphiemu etc. above with high and low ISR Errors _subAnaHists->AddAnaHist(new TDAnaHist("dilDphi_ISRup", "dphi, high ISR", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphi_ISRdn", "dphi, low ISR", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiee_ISRup", "dphi of electrons, high ISR", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiee_ISRdn", "dphi of electrons, low ISR", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiemu_ISRup", "dphi of electron and muon, high ISR", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiemu_ISRdn", "dphi of electron and muon, low ISR", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphimumu_ISRup", "dphi of muons, high ISR", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphimumu_ISRdn", "dphi of muons, low ISR", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); //TD histograms corresponding to the dilDphiemu etc. above with high and low Fake Errors _subAnaHists->AddAnaHist(new TDAnaHist("dilDphi_Fakeup", "dphi, high Fake", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphi_Fakedn", "dphi, low Fake", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiee_Fakeup", "dphi of electrons, high Fake", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiee_Fakedn", "dphi of electrons, low Fake", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiemu_Fakeup", "dphi of electron and muon, high Fake", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphiemu_Fakedn", "dphi of electron and muon, low Fake", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphimumu_Fakeup", "dphi of muons, high Fake", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphimumu_Fakedn", "dphi of muons, low Fake", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDphi_TMVA", "dphi from TMVA selection", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilDR", "dilepton dR", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); //_subAnaHists->AddAnaHist(new TDAnaHist("LeptonEt", "Lepton Et", 0.0, 30.0, 30, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("Weight", ("Weight for" + _dilset.GetDilString()).c_str(), 0.7, 1.1, 80, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("WeightError", ("Weight Error for " + _dilset.GetDilString()).c_str(), 0.0, 0.1, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("RelWeightError", ("Relative Weight Error for " + _dilset.GetDilString()).c_str(), 0.0, 0.1, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("JetNumBeforeCut","Number of Jets in before Jet cut", 0.0, 10.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("JetNumBeforeCut")->SetAxisLables("# jets","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("MissingETMag","Missing Et before missing et cut", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("MissingETMag")->SetAxisLables("Missing Et (GeV)","Events"); //_subAnaHists->AddAnaHist(new TDAnaHist("dilmassmin",("dil mass in"+ _dilset.GetDilString()+" before dil mass cut").c_str(), 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilmassmax","dilepton mass before dilepton mass cut", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("dilmassmax")->SetAxisLables("dilepton mass (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("TotalEt","total Et in before total et cut", 0.0, 500.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("TotalEt")->SetAxisLables("total Et (GeV)","Events"); //_subAnaHists->AddAnaHist(new TDAnaHist("Ht",("Ht"+ _dilset.GetDilString()+" before Ht cut").c_str(), 0.0, 500.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("LeadJetEt_anyN","Lead jet Et for all jets before Jet cut", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("LeadJetEt_anyN")->SetAxisLables("jet Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("LeadJetEt_1Jet","Lead jet Et for one jet before Jet cut", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("LeadJetEt_1Jet")->SetAxisLables("jet Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("LeadJetEt_2Jet","Lead jet Et for two jets in before Jet cut", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("LeadJetEt_2Jet")->SetAxisLables("jet Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("SecondJetEt_2Jet","Second jet Et for two jets before Jet cut", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("SecondJetEt_2Jet")->SetAxisLables("jet Et (GeV)","Events"); if(_drawhists) { //ee, emu, and mumu plots //EE---------------------------------------------- _subAnaHists->AddAnaHist(new TDAnaHist("JetNumBeforeCut_ee","Number of Jets in before Jet cut of electrons", 0.0, 10.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MissingETMag_ee","Missing Et before missing et cut of electrons", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilmassmax_ee","dilepton mass before dilepton mass cut of electrons", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("TotalEt_ee","total Et in before total et cut of electrons", 0.0, 500.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("LeadJetEt_anyN_ee","Lead jet Et for all jets before Jet cut of electrons", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("LeadJetEt_1Jet_ee","Lead jet Et for one jet before Jet cut of electrons", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("LeadJetEt_2Jet_ee","Lead jet Et for two jets in before Jet cut of electrons", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("SecondJetEt_2Jet_ee","Second jet Et for two jets before Jet cut of electrons", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("JetNumBeforeCut_ee")->SetAxisLables("# jets in ee","Events"); _subAnaHists->GetAnaHist("MissingETMag_ee")->SetAxisLables("Missing Et (GeV) in ee","Events"); _subAnaHists->GetAnaHist("dilmassmax_ee")->SetAxisLables("dilepton mass (GeV) in ee","Events"); _subAnaHists->GetAnaHist("TotalEt_ee")->SetAxisLables("total Et (GeV) in ee","Events"); _subAnaHists->GetAnaHist("LeadJetEt_anyN_ee")->SetAxisLables("jet Et (GeV) in ee","Events"); _subAnaHists->GetAnaHist("LeadJetEt_1Jet_ee")->SetAxisLables("jet Et (GeV) in ee","Events"); _subAnaHists->GetAnaHist("LeadJetEt_2Jet_ee")->SetAxisLables("jet Et (GeV) in ee","Events"); _subAnaHists->GetAnaHist("SecondJetEt_2Jet_ee")->SetAxisLables("jet Et (GeV) in ee","Events"); //EMU----------------------------------------------- _subAnaHists->AddAnaHist(new TDAnaHist("JetNumBeforeCut_emu","Number of Jets in before Jet cut of electron and muon", 0.0, 10.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MissingETMag_emu","Missing Et before missing et cut of electron and muon", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilmassmax_emu","dilepton mass before dilepton mass cut of electron and muon", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("TotalEt_emu","total Et in before total et cut of electron and muon", 0.0, 500.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("LeadJetEt_anyN_emu","Lead jet Et for all jets before Jet cut of electron and muon", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("LeadJetEt_1Jet_emu","Lead jet Et for one jet before Jet cut of electron and muon", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("LeadJetEt_2Jet_emu","Lead jet Et for two jets in before Jet cut of electron and muon", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("SecondJetEt_2Jet_emu","Second jet Et for two jets before Jet cut of electron and muon", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("JetNumBeforeCut_emu")->SetAxisLables("# jets in e mu","Events"); _subAnaHists->GetAnaHist("MissingETMag_emu")->SetAxisLables("Missing Et (GeV) in e mu","Events"); _subAnaHists->GetAnaHist("dilmassmax_emu")->SetAxisLables("dilepton mass (GeV) in e mu","Events"); _subAnaHists->GetAnaHist("TotalEt_emu")->SetAxisLables("total Et (GeV) in e mu","Events"); _subAnaHists->GetAnaHist("LeadJetEt_anyN_emu")->SetAxisLables("jet Et (GeV) in e mu","Events"); _subAnaHists->GetAnaHist("LeadJetEt_1Jet_emu")->SetAxisLables("jet Et (GeV) in e mu","Events"); _subAnaHists->GetAnaHist("LeadJetEt_2Jet_emu")->SetAxisLables("jet Et (GeV) in e mu","Events"); _subAnaHists->GetAnaHist("SecondJetEt_2Jet_emu")->SetAxisLables("jet Et (GeV) in e mu","Events"); //MUMU----------------------------------------------- _subAnaHists->AddAnaHist(new TDAnaHist("JetNumBeforeCut_mumu","Number of Jets in before Jet cut of muons", 0.0, 10.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MissingETMag_mumu","Missing Et before missing et cut of muons", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilmassmax_mumu","dilepton mass before dilepton mass cut of muons", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("TotalEt_mumu","total Et in before total et cut of muons", 0.0, 500.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("LeadJetEt_anyN_mumu","Lead jet Et for all jets before Jet cut of muons", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("LeadJetEt_1Jet_mumu","Lead jet Et for one jet before Jet cut of muons", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("LeadJetEt_2Jet_mumu","Lead jet Et for two jets in before Jet cut of muons", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("SecondJetEt_2Jet_mumu","Second jet Et for two jets before Jet cut of muons", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("JetNumBeforeCut_mumu")->SetAxisLables("# jets in mu mu","Events"); _subAnaHists->GetAnaHist("MissingETMag_mumu")->SetAxisLables("Missing Et (GeV) in mu mu","Events"); _subAnaHists->GetAnaHist("dilmassmax_mumu")->SetAxisLables("dilepton mass (GeV) in mu mu","Events"); _subAnaHists->GetAnaHist("TotalEt_mumu")->SetAxisLables("total Et (GeV) in mu mu","Events"); _subAnaHists->GetAnaHist("LeadJetEt_anyN_mumu")->SetAxisLables("jet Et (GeV) in mu mu","Events"); _subAnaHists->GetAnaHist("LeadJetEt_1Jet_mumu")->SetAxisLables("jet Et (GeV) in mu mu","Events"); _subAnaHists->GetAnaHist("LeadJetEt_2Jet_mumu")->SetAxisLables("jet Et (GeV) in mu mu","Events"); _subAnaHists->GetAnaHist("SecondJetEt_2Jet_mumu")->SetAxisLables("jet Et (GeV) in mu mu","Events"); //END OF 7708 plots -------------------------------- _subAnaHists->AddAnaHist(new TDAnaHist("Nm1JetNumBeforeCut",("Number of Jets in"+ _dilset.GetDilString()+" in Nm1 Jet cut").c_str(), 0.0, 10.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1MissingETMag",("Missing Et in"+ _dilset.GetDilString()+" in Nm1 missing et cut").c_str(), 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); //_subAnaHists->AddAnaHist(new TDAnaHist("Nm1dilmassmin",("dil mass in"+ _dilset.GetDilString()+" in Nm1 dil mass cut").c_str(), 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1dilmassmax",("dil mass in"+ _dilset.GetDilString()+" in Nm1 dil mass max cut").c_str(), 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1TotalEt",("total et in"+ _dilset.GetDilString()+" in Nm1 total et cut").c_str(), 0.0, 500.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1LeadJetEt_anyN",("Lead jet Et for all jets in"+ _dilset.GetDilString()+" in Nm1 Jet cut").c_str(), 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1LeadJetEt_1Jet",("Lead jet Et for one jet in "+ _dilset.GetDilString()+" in Nm1 Jet cut").c_str(), 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1LeadJetEt_2Jet",("Lead jet Et for two jets in "+ _dilset.GetDilString()+" in Nm1 Jet cut").c_str(), 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1SecondJetEt_2Jet",("Second jet Et for two jets in "+ _dilset.GetDilString()+" in Nm1 Jet cut").c_str(), 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("Missing_Et","Missing Et", 0.0, 250.0, 250, _datasource.c_str(), "HistSetDesc")); //_subAnaHists->AddAnaHist(new TDAnaHist("dilDphi", ("dildphi in "+ _dilset.GetDilString()).c_str(), 0.0, 3.142, 6, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("Lepton1Et",("highest lepton Et in "+ _dilset.GetDilString()).c_str(), 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("Lepton2Et",("secondhighest lepton Et in "+ _dilset.GetDilString()).c_str(), 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMPPhi",("CMP Phi in "+ _dilset.GetDilString()).c_str(), 0, (3.142*2), 240, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMXEtaPhi",("CMX EtaPhi in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMXDeanEtaPhi",("CMX DeanEtaPhi in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); } _subAnaHists->AddAnaHist(new TDAnaHist("CMUEtaPhi",("CMU EtaPhi in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("CMUEtaPhi")->SetAxisLables("eta","phi (rads)"); _subAnaHists->AddAnaHist(new TDAnaHist("CMUPEtaPhi",("CMUP EtaPhi in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("CMUPEtaPhi")->SetAxisLables("eta","phi (rads)"); _subAnaHists->AddAnaHist(new TDAnaHist("CMPEtaPhi",("CMP EtaPhi in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("CMPEtaPhi")->SetAxisLables("eta","phi (rads)"); if(_drawhists) { _subAnaHists->AddAnaHist(new TDAnaHist("CMIOEtaPhi",("CMIO EtaPhi in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMIOEtaPhiCMUP",("CMUP_CMIO EtaPhi of CMUP in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMIOEtaPhiCMIO",("CMUP_CMIO EtaPhi of CMIO in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMUPEtaPhiCMUP",("CMUP_CMUP EtaPhi of CMUP in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMUEtaPhiCMUP",("CMUP_CMU EtaPhi of CMUP in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMUEtaPhiCMU",("CMUP_CMU EtaPhi of CMU in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMPEtaPhiCMUP",("CMUP_CMP EtaPhi of CMUP in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMPEtaPhiCMP",("CMUP_CMP EtaPhi of CMP in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMXEtaPhiCMUP",("CMUP_CMX EtaPhi of CMUP in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMXEtaPhiCMX",("CMUP_CMX EtaPhi of CMX in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMIOEtaPhiCMX",("CMX_CMIO EtaPhi of CMX in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMIOEtaPhiCMIO",("CMX_CMIO EtaPhi of CMIO in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMUEtaPhiCMX",("CMX_CMU EtaPhi of CMX in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMUEtaPhiCMU",("CMX_CMU EtaPhi of CMU in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMPEtaPhiCMX",("CMX_CMP EtaPhi of CMX in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMPEtaPhiCMP",("CMX_CMP EtaPhi of CMP in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMXEtaPhiCMX",("CMX_CMX EtaPhi of CMX in "+ _dilset.GetDilString()).c_str(), -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); /*_subAnaHists->AddAnaHist(new TDAnaHist("TCE_TCEmass", "TCE_TCE Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("TCE_PHXmass", "TCE_PHX Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("PHX_PHXmass", "PHX_PHX Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMUPmass", "CMUP_CMUP Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMUmass", "CMUP_CMU Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMPmass", "CMUP_CMP Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMXmass", "CMUP_CMX Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMIOmass", "CMUP_CMIO Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMXmass", "CMX_CMX Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMUmass", "CMX_CMU Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMPmass", "CMX_CMP Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMIOmass", "CMX_CMIO Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_BMUmass", "CMUP_BMU Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_BMUmass", "CMX_BMU Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BMU_BMUmass", "BMU_BMU Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BMU_CMPmass", "CMP_BMU Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BMU_CMIOmass", "CMIO_BMU Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BMU_CMUmass", "CMU_BMU Mass", 70.0, 120.0, 50, _datasource.c_str(), "HistSetDesc"));*/ } /*_subAnaHists->AddAnaHist(new TDAnaHist("allmassfull", "Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("TCE_TCEmassfull", "TCE_TCE Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("TCE_PHXmassfull", "TCE_PHX Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("PHX_PHXmassfull", "PHX_PHX Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMUPmassfull", "CMUP_CMUP Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMUmassfull", "CMUP_CMU Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMPmassfull", "CMUP_CMP Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMXmassfull", "CMUP_CMX Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMIOmassfull", "CMUP_CMIO Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMXmassfull", "CMX_CMX Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMUmassfull", "CMX_CMU Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMPmassfull", "CMX_CMP Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMIOmassfull", "CMX_CMIO Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_BMUmassfull", "CMUP_BMU Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_BMUmassfull", "CMX_BMU Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BMU_BMUmassfull", "BMU_BMU Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BMU_CMPmassfull", "CMP_BMU Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BMU_CMIOmassfull", "CMIO_BMU Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BMU_CMUmassfull", "CMU_BMU Mass Full Range", 0.0, 200.0, 50, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("allmass040", "Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("TCE_TCEmass040", "TCE_TCE Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("TCE_PHXmass040", "TCE_PHX Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("PHX_PHXmass040", "PHX_PHX Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMUPmass040", "CMUP_CMUP Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMUmass040", "CMUP_CMU Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMPmass040", "CMUP_CMP Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMXmass040", "CMUP_CMX Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_CMIOmass040", "CMUP_CMIO Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMXmass040", "CMX_CMX Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMUmass040", "CMX_CMU Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMPmass040", "CMX_CMP Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_CMIOmass040", "CMX_CMIO Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMUP_BMUmass040", "CMUP_BMU Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("CMX_BMUmass040", "CMX_BMU Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BMU_BMUmass040", "BMU_BMU Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BMU_CMPmass040", "CMP_BMU Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BMU_CMIOmass040", "CMIO_BMU Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("BMU_CMUmass040", "CMU_BMU Mass 0-40 Range", 0.0, 40.0, 40, _datasource.c_str(), "HistSetDesc")); */ /*_subAnaHists->AddAnaHist(new TDAnaHist("dilmassbox_run", "dilmassbox_run", 140000, 210000, 110, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilmassbox_evt", "dilmassbox_evt", 0, 100, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilmassbox_etaphi", "dilmassbox_etaphi", -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilmassbox_eta", "dilmassbox_eta", -1.5, 1.5, 15, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilmassbox_phi", "dilmassbox_phi", 0, (3.142*2), 15, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilmassbox_LepR", "dilmassbox_LepR", 0.0, 7.0, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("dilmassbox_LepDphi", "dilmassbox_LepDphi", 0, 3.142, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("outdilmassbox_run", "outdilmassbox_run", 140000, 210000, 110, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("outdilmassbox_evt", "outdilmassbox_evt", 0, 100, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("outdilmassbox_etaphi", "outdilmassbox_etaphi", -1.5, 1.5, 60, 0, (3.142*2), 60, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("outdilmassbox_eta", "outdilmassbox_eta", -1.5, 1.5, 15, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("outdilmassbox_phi", "outdilmassbox_phi", 0, (3.142*2), 15, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("outdilmassbox_LepR", "outdilmassbox_LepR", 0.0, 7.0, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("outdilmassbox_LepDphi", "outdilmassbox_LepDphi", 0, 3.142, 20, _datasource.c_str(), "HistSetDesc"));*/ //_subAnaHists->AddAnaHist(new TDAnaHist("Rawlowmass_LepDphi", "Rawlowmass_LepDphi", 0, 2*3.142, 20, _datasource.c_str(), "HistSetDesc")); //_subAnaHists->AddAnaHist(new TDAnaHist("Rawlowmass_LepR", "Rawlowmass_LepR", 0.0, 7.0, 20, _datasource.c_str(), "HistSetDesc")); //_subAnaHists->AddAnaHist(new TDAnaHist("Rawhighmass_LepDphi", "Rawhighmass_LepDphi", 0, 2*3.142, 20, _datasource.c_str(), "HistSetDesc")); //_subAnaHists->AddAnaHist(new TDAnaHist("Rawhighmass_LepR", "Rawhighmass_LepR", 0.0, 7.0, 20, _datasource.c_str(), "HistSetDesc")); //_subAnaHists->AddAnaHist(new TDAnaHist("Rawlowmass_Lepphi", "Rawlowmass_Lepphi", 0, 2*3.142, 20, _datasource.c_str(), "HistSetDesc")); //_subAnaHists->AddAnaHist(new TDAnaHist("Rawhighmass_Lepphi", "Rawhighmass_Lepphi", 0, 2*3.142, 20, _datasource.c_str(), "HistSetDesc")); for(int type=DilType::TCE_TCE; type<=DilType::BMU_SCMIO; ++type) { /*_subAnaHists->AddAnaHist(new TDAnaHist(((_dilType.Int2StringDash(type)) + " dilDphilike").c_str(), ((_dilType.Int2StringDash(type)) + " dilDphilike").c_str(), 0.0, 3.141592654, 200, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist(((_dilType.Int2StringDash(type)) + " dilDphilike").c_str())->SetDraw(false);*/ //TD remove these for now - they are not needed... // _subAnaHists->AddAnaHist(new TDAnaHist(((_dilType.Int2StringDash(type)) + " 1stleptonET").c_str(), // ((_dilType.Int2StringDash(type)) + " 1stleptonET").c_str(), 0.0, 50.0, 100, _datasource.c_str(), "HistSetDesc")); /*_subAnaHists->AddAnaHist(new TDAnaHist(((_dilType.Int2StringDash(type)) + " weight").c_str(), ((_dilType.Int2StringDash(type)) + " weight").c_str(), 0.7, 1.1, 80, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist(((_dilType.Int2StringDash(type)) + " weight").c_str())->GetHist()->StatOverflows(kTRUE); _subAnaHists->GetAnaHist(((_dilType.Int2StringDash(type)) + " weight").c_str())->SetDraw(false); _subAnaHists->AddAnaHist(new TDAnaHist(((_dilType.Int2StringDash(type)) + " relweighterror").c_str(), ((_dilType.Int2StringDash(type)) + " relweighterror").c_str(), 0.0, 0.1, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist(((_dilType.Int2StringDash(type)) + " relweighterror").c_str())->GetHist()->StatOverflows(kTRUE); _subAnaHists->GetAnaHist(((_dilType.Int2StringDash(type)) + " relweighterror").c_str())->SetDraw(false); _subAnaHists->AddAnaHist(new TDAnaHist(((_dilType.Int2StringDash(type)) + " rawweight").c_str(), ((_dilType.Int2StringDash(type)) + " rawweight").c_str(), 0.7, 1.1, 80, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist(((_dilType.Int2StringDash(type)) + " rawweight").c_str())->SetDraw(false); */ if(type<=DilType::CMX_CMIO) _subAnaHists->AddAnaHist(new TDAnaHist(((_dilType.Int2StringDash(type)) + "lowdilmass").c_str(), ((_dilType.Int2StringDash(type)) + "lowdilmass").c_str(), 0.0, 60, 60, _datasource.c_str(), "HistSetDesc")); } if(_drawhists) { for(int leptype=LeptonType::TCE; leptype<=LeptonType::BMU; ++leptype) { _subAnaHists->AddAnaHist(new TDAnaHist(((_leptonType.Int2String(leptype)) + " leptonET").c_str(), ((_leptonType.Int2String(leptype)) + " leptonET").c_str(), 0.0, 50.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist(((_leptonType.Int2String(leptype)) + "_leptonisol_trk").c_str(), ((_leptonType.Int2String(leptype)) + " lepton isol trk").c_str(), 0.0, 1.4, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist(((_leptonType.Int2String(leptype)) + "_leptonisol_cal").c_str(), ((_leptonType.Int2String(leptype)) + " lepton isol cal").c_str(), 0.0, 1.4, 100, _datasource.c_str(), "HistSetDesc")); } } _subAnaHists->AddAnaHist(new TDAnaHist("luminosity", "luminosity", 0.0, 1500.0, 1500, _datasource.c_str(), "HistSetDesc")); if(_drawhists)_subAnaHists->AddAnaHist(new TDAnaHist("WWmetsig", "WW missing Et significance", 0.0, 16.0, 32, _datasource.c_str(), "HistSetDesc")); if(_drawhists)_subAnaHists->GetAnaHist("WWmetsig")->SetAxisLables("Missing Et significance","Events"); if(_drawhists)_subAnaHists->AddAnaHist(new TDAnaHist("WWdilmass", "WW dilepton mass", 0.0, 250.0, 10, _datasource.c_str(), "HistSetDesc")); if(_drawhists)_subAnaHists->GetAnaHist("WWdilmass")->SetAxisLables("Dilepton Mass (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("WWmetmag", "WW missing Et", 0.0, 200.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("WWmetmag")->SetAxisLables("Missing Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("WWmetmag_ee", "WW missing Et ee", 0.0, 200.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("WWmetmag_emu", "WW missing Et emu", 0.0, 200.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("WWmetmag_mumu", "WW missing Et mumu", 0.0, 200.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("FrankWWmetmag", "Frank WW missing Et", 0.0, 200.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("FrankWWmetmag_ee", "Frank WW missing Et ee", 0.0, 200.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("FrankWWmetmag_emu", "Frank WW missing Et emu", 0.0, 200.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("FrankWWmetmag_mumu", "Frank WW missing Et mumu", 0.0, 200.0, 10, _datasource.c_str(), "HistSetDesc")); if(_drawhists)_subAnaHists->AddAnaHist(new TDAnaHist("WWsumEt", "WW total Et", 0.0, 600.0, 32, _datasource.c_str(), "HistSetDesc")); if(_drawhists)_subAnaHists->GetAnaHist("WWsumEt")->SetAxisLables("Total Et (GeV)","Events"); if(_drawhists)_subAnaHists->AddAnaHist(new TDAnaHist("WWlepPt", "WW lepton pT", 0.0, 200.0, 10, _datasource.c_str(), "HistSetDesc")); if(_drawhists)_subAnaHists->GetAnaHist("WWlepPt")->SetAxisLables("Lepton pT (GeV)","#leptons"); _subAnaHists->AddAnaHist(new TDAnaHist("metspec", "Met Special", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("metsigspec", "Met Significance Special ", 0.0, 16.0, 32, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("WeightError")->GetHist()->StatOverflows(kTRUE); _subAnaHists->GetAnaHist("Weight")->GetHist()->StatOverflows(kTRUE); _subAnaHists->AddAnaHist(new TDAnaHist("MatrixTest", "mattest", 160.0, 200.0, 20, _datasource.c_str(), "HistSetDesc")); std::cout<<"creating hists in "<<_datasource<AddAnaHist(new TDAnaHist("MVA_Cuts", "MVA_Cuts", 0, 2, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_Cuts_cut1", "MVA_Cuts_cut1", 0, 2, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_Cuts", "MVA2_Cuts", 0, 2, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_Cuts_cut1", "MVA2_Cuts_cut1", 0, 2, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_Cuts_cut2", "MVA2_Cuts_cut2", 0, 2, 20, _datasource.c_str(), "HistSetDesc") ); } if (Use_Likelihood ) {_subAnaHists->AddAnaHist(new TDAnaHist("MVA_Likelihood", "MVA_Likelihood", -1, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_Likelihood_cut1", "MVA_Likelihood_cut1", -1, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_Likelihood", "MVA2_Likelihood", -1, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_Likelihood_cut1", "MVA2_Likelihood_cut1", -1, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_Likelihood_cut2", "MVA2_Likelihood_cut2", -1, 1, 20, _datasource.c_str(), "HistSetDesc") ); } if (Use_LikelihoodD ) {_subAnaHists->AddAnaHist(new TDAnaHist("MVA_LikelihoodD", "MVA_LikelihoodD", -1, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_LikelihoodD_cut1", "MVA_LikelihoodD_cut1", -1, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_LikelihoodD", "MVA2_LikelihoodD", -1, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_LikelihoodD_cut1", "MVA2_LikelihoodD_cut1", -1, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_LikelihoodD_cut2", "MVA2_LikelihoodD_cut2", -1, 1, 20, _datasource.c_str(), "HistSetDesc") ); } if (Use_PDERS ) {_subAnaHists->AddAnaHist(new TDAnaHist("MVA_PDERS", "MVA_PDERS", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_PDERS_cut1", "MVA_PDERS_cut1", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_PDERS", "MVA2_PDERS", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_PDERS_cut1", "MVA2_PDERS_cut1", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_PDERS_cut2", "MVA2_PDERS_cut2", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); } if (Use_HMatrix ) {_subAnaHists->AddAnaHist(new TDAnaHist("MVA_HMatrix", "MVA_HMatrix", -1.25, 1.25, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_HMatrix_cut1", "MVA_HMatrix_cut1", -1.25, 1.25, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_HMatrix", "MVA2_HMatrix", -1.25, 1.25, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_HMatrix_cut1", "MVA2_HMatrix_cut1", -1.25, 1.25, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_HMatrix_cut2", "MVA2_HMatrix_cut2", -1.25, 1.25, 20, _datasource.c_str(), "HistSetDesc") ); } if (Use_Fisher ) {_subAnaHists->AddAnaHist(new TDAnaHist("MVA_Fisher", "MVA_Fisher", -4, 4, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_Fisher_cut1", "MVA_Fisher_cut1", -4, 4, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_Fisher", "MVA2_Fisher", -2, 2, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_Fisher_cut1", "MVA2_Fisher_cut1", -2, 2, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_Fisher_cut2", "MVA2_Fisher_cut2", -2, 2, 20, _datasource.c_str(), "HistSetDesc") ); } if (Use_CFMlpANN ) {_subAnaHists->AddAnaHist(new TDAnaHist("MVA_CFMlpANN", "Drell-Yan trained NN", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_CFMlpANN_cut1", "MVA_CFMlpANN_cut1", 0, 0.1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_CFMlpANN", "WW trained NN", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_CFMlpANN_cut1", "MVA2_CFMlpANN_cut1", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_CFMlpANN_cut2", "MVA2_CFMlpANN_cut2", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_CFMlpANN_cut2_0", "MVA2_CFMlpANN_cut2_0", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_CFMlpANN_cut2_1", "MVA2_CFMlpANN_cut2_1", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_CFMlpANN_cut2_2", "MVA2_CFMlpANN_cut2_2", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_CFMlpANN_cut2_3", "MVA2_CFMlpANN_cut2_3", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_CFMlpANN_cut2_4", "MVA2_CFMlpANN_cut2_4", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_CFMlpANN_cut2_5", "MVA2_CFMlpANN_cut2_5", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_CFMlpANN_cut2_6", "MVA2_CFMlpANN_cut2_6", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_CFMlpANN_cut2_7", "WW trained NN with Drell Yan cut", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_CFMlpANN_cut2_8", "MVA2_CFMlpANN_cut2_8", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_CFMlpANN_cut2_9", "MVA2_CFMlpANN_cut2_9", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); } if (Use_TMlpANN) { _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN", "Drell Yan Neural Net", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_fine", "Drell Yan Neural Net", 0.8, 1.2,200, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_cut1", "Drell Yan Neural Net with cut > 0.95", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN","WW Neural Net", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1", "WW Neural Net with DY cut", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); //_subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_ucsd", "WW Neural Net with DY cut ucsd", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); /*_subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_JESup", "WW+DYcut JESup", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_JESdn", "WW+DYcut JESdn", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_LESup", "WW+DYcut LESup", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_LESdn", "WW+DYcut LESdn", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_Fakeup", "WW+DYcut Fakeup", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_Fakedn", "WW+DYcut Fakedn", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_ISRup", "WW+DYcut ISRup", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_ISRdn", "WW+DYcut ISRdn", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); //_subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut2", "MVA2_TMlpANN_cut2", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_PDF", "WW+DYcut, PDFs", 0.-0.2,1.2,28, 0, 41, 41, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_PDFup", "WW+DYcut, high PDF", 0.-0.2,1.2,28, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_PDFdn", "WW+DYcut, low PDF", 0.-0.2,1.2,28, _datasource.c_str(), "HistSetDesc"));*/ _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_ee", "Drell Yan Neural Net in ee", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_fine_ee", "Drell Yan Neural Net in ee", 0.8, 1.2,200, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_fine_ee_srb", "Drell Yan Neural Net in ee signal over root background", 0.8, 1.2,200, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_fine_ee_srdyb", "Drell Yan Neural Net in ee signal over root DY background", 0.8, 1.2,200, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_cut1_ee", "Drell Yan Neural Net with cut in ee", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_ee","WW Neural Net in ee", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_ee", "WW Neural Net with DY cut in ee", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_JESup_ee", "WW+DYcut JESup in ee", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_JESdn_ee", "WW+DYcut JESdn in ee", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_LESup_ee", "WW+DYcut LESup in ee", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_LESdn_ee", "WW+DYcut LESdn in ee", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_Fakeup_ee", "WW+DYcut Fakeup in ee", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_Fakedn_ee", "WW+DYcut Fakedn in ee", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_ISRup_ee", "WW+DYcut ISRup in ee", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_ISRdn_ee", "WW+DYcut ISRdn in ee", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_PDF_ee", "WW+DYcut, PDFs in ee", 0.-0.2,1.2,28, 0, 41, 41, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_PDFup_ee", "WW+DYcut, high PDF in ee", 0.-0.2,1.2,28, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_PDFdn_ee", "WW+DYcut, low PDF in ee", 0.-0.2,1.2,28, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_emu", "Drell Yan Neural Net in emu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_fine_emu", "Drell Yan Neural Net in emu", 0.8, 1.2,200, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_fine_emu_srb", "Drell Yan Neural Net in emu signal over root background", 0.8, 1.2,200, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_fine_emu_srdyb", "Drell Yan Neural Net in emu signal over root DY background", 0.8, 1.2,200, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_cut1_emu", "Drell Yan Neural Net with cut in emu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_emu","WW Neural Net in emu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_emu", "WW Neural Net with DY cut in emu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_JESup_emu", "WW+DYcut JESup in emu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_JESdn_emu", "WW+DYcut JESdn in emu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_LESup_emu", "WW+DYcut LESup in emu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_LESdn_emu", "WW+DYcut LESdn in emu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_Fakeup_emu", "WW+DYcut Fakeup in emu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_Fakedn_emu", "WW+DYcut Fakedn in emu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_ISRup_emu", "WW+DYcut ISRup in emu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_ISRdn_emu", "WW+DYcut ISRdn in emu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_PDF_emu", "WW+DYcut, PDFs in emu", 0.-0.2,1.2,28, 0, 41, 41, _datasource.c_str(),"HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_PDFup_emu", "WW+DYcut, high PDF in emu", 0.-0.2,1.2,28, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_PDFdn_emu", "WW+DYcut, low PDF in emu", 0.-0.2,1.2,28, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_mumu", "Drell Yan Neural Net in mumu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_fine_mumu", "Drell Yan Neural Net in mumu", 0.8, 1.2,200, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_fine_mumu_srb", "Drell Yan Neural Net in mumu signal over root background", 0.8, 1.2,200, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_fine_mumu_srdyb", "Drell Yan Neural Net in mumu signal over root DY background", 0.8, 1.2,200, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_TMlpANN_cut1_mumu", "Drell Yan Neural Net with cut in mumu", -0.2,1.2,28,_datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_mumu","WW Neural Net in mumu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_mumu", "WW Neural Net with DY cut in mumu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_JESup_mumu", "WW+DYcut JESup in mumu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_JESdn_mumu", "WW+DYcut JESdn in mumu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_LESup_mumu", "WW+DYcut LESup in mumu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_LESdn_mumu", "WW+DYcut LESdn in mumu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_Fakeup_mumu", "WW+DYcut Fakeup in mumu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_Fakedn_mumu", "WW+DYcut Fakedn in mumu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_ISRup_mumu", "WW+DYcut ISRup in mumu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_ISRdn_mumu", "WW+DYcut ISRdn in mumu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_PDF_mumu", "WW+DYcut, PDFs in mumu", 0.-0.2,1.2,28, 0, 41,41,_datasource.c_str(),"HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_PDFup_mumu", "WW+DYcut, high PDF in mumu", 0.-0.2,1.2,28, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_PDFdn_mumu", "WW+DYcut, low PDF in mumu", 0.-0.2,1.2,28, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_dilmass_std", "Passed DYCut Variable dilmass", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_samesign", "WW Neural Net in samesign", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_samesign_ee", "WW Neural Net in samesign ee", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_samesign_emu", "WW Neural Net in samesign emu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_samesign_mumu", "WW Neural Net in samesign mumu", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_samesign_tcetce", "WW Neural Net in samesign tcetce", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_TMlpANN_cut1_samesign_cmupcmup", "WW Neural Net in samesign cmupcmup", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); if(_drawNNhists && initTMVA) { //#include "AnaHistBookHighMllControlNNInputVar.cc" //#include "AnaHistBookHighMllControlNNDYCut.cc" _subAnaHists->AddAnaHist(new TDAnaHist("HighMllControlNN_MVA_TMlpANN", "HighMllControlNN Drell Yan Neural Net", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("HighMllControlNN_MVA2_TMlpANN", "HighMllControlNN WW Neural Net", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("HighMllControlNN_MVA2_TMlpANN_cut1", "HighMllControlNN WW Neural Net with DY cut", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); //#include "AnaHistBookZPeakNNInputVar.cc" //#include "AnaHistBookZPeakNNDYCut.cc" _subAnaHists->AddAnaHist(new TDAnaHist("ZPeakNN_MVA_TMlpANN", "ZPeakNN Drell Yan Neural Net", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("ZPeakNN_MVA2_TMlpANN", "ZPeakNN WW Neural Net", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("ZPeakNN_MVA2_TMlpANN_cut1", "ZPeakNN WW Neural Net with DY cut", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); /*_subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_LepAEn", "NN Variable DYNN cut LepAEn", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_LepBEn", "NN Variable DYNN cut LepBEn", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_dilmass", "NN Variable DYNN cut dilmass", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_metmag", "NN Variable DYNN cut metmag", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_addEt", "NN Variable DYNN cut addEt", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_dPhiMetLJ", "NN Variable DYNN cut dPhiMetLJ", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_ntightjets", "NN Variable DYNN cut tightjets", 0.0, 10.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_jet1_Et", "NN Variable DYNN cut jet1_Et", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_jet2_Et", "NN Variable DYNN cut jet2_Et", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_dildphi", "NN Variable DYNN cut dildphi", 0.0, 3.141592654, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_lepR", "NN Variable DYNN cut lepR", 0.0, 7.0, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_metsig", "NN Variable DYNN cut metsig", 0.0, 16.0, 32, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_diltype", "NN Variable DYNN cut diltype", 0, 3, 3, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_Mt_ll", "NN Variable DYNN cut Mt_ll", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_Mt_llMet", "NN Variable DYNN cut Mt_llMet", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_Mt_All", "NN Variable DYNN cut Mt_All", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_Isr", "NN Variable DYNN cut Isr", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DYNNcut_DilPhillCorr","NN Variable DYNN cut DilPhillCorr", -1, 3.141592654, 20, _datasource.c_str(), "HistSetDesc"));*/ } /*if(_drawNNhists3 && initTMVA) { #include "AnaHistBookWWNNlowCut.cc" #include "AnaHistBookWWNNmidCut.cc" #include "AnaHistBookWWNNhighCut.cc" }*/ if(_drawNNhists2 && initTMVA) { //#include "AnaHistBookLepEtControlNNInputVar.cc" //#include "AnaHistBookLepEtControlNNDYCut.cc" _subAnaHists->AddAnaHist(new TDAnaHist("LepEtControlNN_MVA_TMlpANN", "LepEtControlNN Drell Yan Neural Net", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("LepEtControlNN_MVA2_TMlpANN", "LepEtControlNN WW Neural Net", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("LepEtControlNN_MVA2_TMlpANN_cut1", "LepEtControlNN WW Neural Net with DY cut", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); //#include "AnaHistBookNNDYCut.cc" //#include "AnaHistBookNNInputVar.cc" } /*if(_drawNNhists4 && initTMVA) { #include "AnaHistBookNNDYCutMid.cc" #include "AnaHistBookLowMllControlNNInputVar.cc" #include "AnaHistBookLowMllControlNNDYCut.cc" // _subAnaHists->AddAnaHist(new TDAnaHist("LepEtControlNN_MVA_TMlpANN", "LepEtControlNN Drell Yan Neural Net", -0.2,1.2,28, _datasource.c_str(), "HistSetDesc") ); } if(_drawNNhists5 && initTMVA) { #include "AnaHistBookLMetHMetSNNInputVar.cc" #include "AnaHistBookLMetSHMetNNInputVar.cc" }*/ } if (Use_BDT ) {_subAnaHists->AddAnaHist(new TDAnaHist("MVA_BDT", "MVA_BDT", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA_BDT_cut1", "MVA_BDT_cut1", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_BDT", "MVA2_BDT", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_BDT_cut1", "MVA2_BDT_cut1", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); _subAnaHists->AddAnaHist(new TDAnaHist("MVA2_BDT_cut2", "MVA2_BDT_cut2", 0, 1, 20, _datasource.c_str(), "HistSetDesc") ); } } //_subAnaHists->AddAnaHist(new TDAnaHist("dilmass_LepBAEn", "dilmass_LepBAEn", 0.0, 200.0, 40, 0.0, 100.0, 100,_datasource.c_str(),"HistSetDesc")); //_subAnaHists->AddAnaHist(new TDAnaHist("dilmass_totEt", "dilmass_totEt", 0.0, 200.0, 40, 0.0, 200.0, 40, _datasource.c_str(),"HistSetDesc")); /*if(_drawhists || initTMVA) { //TD histograms to check NN input variables _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_LepAEn", "NN Variable LepAEn", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("NNVar_LepAEn")->SetAxisLables("Higher Lepton Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_LepBEn", "NN Variable LepBEn", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("NNVar_LepBEn")->SetAxisLables("Lower Lepton Energy GeV","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_LepAEt", "NN Variable LepAEt", 0.0, 200.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_LepAEt_ee", "NN Variable LepAEt_ee", 0.0, 200.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_LepAEt_emu", "NN Variable LepAEt_emu", 0.0, 200.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_LepAEt_mumu", "NN Variable LepAEt_mumu", 0.0, 200.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_LepBEt", "NN Variable LepBEt", 0.0, 200.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_LepBEt_ee", "NN Variable LepBEt_ee", 0.0, 200.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_LepBEt_emu", "NN Variable LepBEt_emu", 0.0, 200.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_LepBEt_mumu", "NN Variable LepBEt_mumu", 0.0, 200.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_dilmass", "NN Variable dilmass", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("NNVar_dilmass")->SetAxisLables("Dilepton Mass (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_metmag", "NN Variable metmag", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("NNVar_metmag")->SetAxisLables("Missing Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_addEt", "NN Variable addEt", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("NNVar_addEt")->SetAxisLables("Sum Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_dPhiMetLJ", "NN Variable dPhiMetLJ", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("NNVar_dPhiMetLJ")->SetAxisLables("Closest object to Missing Et (rads)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_ntightjets", "NN Variable tightjets", 0.0, 10.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("NNVar_ntightjets")->SetAxisLables("Jet Number","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_jet1_Et", "NN Variable jet1_Et", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("NNVar_jet1_Et")->SetAxisLables("Highest Jet Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_jet2_Et", "NN Variable jet2_Et", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("NNVar_jet2_Et")->SetAxisLables("Second Highest Jet Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_dildphi", "NN Variable dildphi", 0.0, 3.141592654, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("NNVar_dildphi")->SetAxisLables("lepton separation (rads)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_lepR", "NN Variable lepR", 0.0, 7.0, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("NNVar_lepR")->SetAxisLables("dilepton R","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_metsig", "NN Variable metsig", 0.0, 16.0, 32, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("NNVar_metsig")->SetAxisLables("Missing Et Significance","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_diltype", "NN Variable diltype", 0, 3, 3, _datasource.c_str(), "HistSetDesc")); // _subAnaHists->GetAnaHist("NNVar_metsig")->SetAxisLables("","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_Mt_ll", "NN Variable Mt_ll", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_Mt_llMet", "NN Variable Mt_llMet", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_Mt_All", "NN Variable Mt_All", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_Isr", "NN Variable Isr", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("NNVar_DilPhillCorr","NN Variable DilPhillCorr", -1, 3.141592654, 20, _datasource.c_str(), "HistSetDesc")); }*/ if(_drawhists) { _subAnaHists->AddAnaHist(new TDAnaHist("dilmassbox_DRbox_dildphi","dildphi 40AddAnaHist(new TDAnaHist("dilmassbox_DRbox_dPhiMetLJ","dPhiMetLJ 40AddAnaHist(new TDAnaHist("dilmassbox_DRbox_lepetass","leptonassym 40AddAnaHist(new TDAnaHist("z0pass","z0 of selected events", -45, 45, 30, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("Dz0pass","z0 of selected events", -5, 5, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->AddAnaHist(new TDAnaHist("PassSameSign_LepAEn", "Passed SameSign Variable LepAEn", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassSameSign_LepAEn")->SetAxisLables("Higher Lepton Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassSameSign_LepBEn", "Passed SameSign Variable LepBEn", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassSameSign_LepBEn")->SetAxisLables("Lower Lepton Energy GeV","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassSameSign_dilmass", "Passed SameSign Variable dilmass", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassSameSign_dilmass")->SetAxisLables("Dilepton Mass (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassSameSign_metmag", "Passed SameSign Variable metmag", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassSameSign_metmag")->SetAxisLables("Missing Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassSameSign_addEt", "Passed SameSign Variable addEt", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassSameSign_addEt")->SetAxisLables("Sum Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassSameSign_dPhiMetLJ", "Passed SameSign Variable dPhiMetLJ", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassSameSign_dPhiMetLJ")->SetAxisLables("Closest object to Missing Et (rads)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassSameSign_ntightjets", "Passed SameSign Variable tightjets", 0.0, 10.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassSameSign_ntightjets")->SetAxisLables("Jet Number","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassSameSign_jet1_Et", "Passed SameSign Variable jet1_Et", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassSameSign_jet1_Et")->SetAxisLables("Highest Jet Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassSameSign_jet2_Et", "Passed SameSign Variable jet2_Et", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassSameSign_jet2_Et")->SetAxisLables("Second Highest Jet Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassSameSign_dildphi", "Passed SameSign Variable dildphi", 0.0, 3.141592654, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassSameSign_dildphi")->SetAxisLables("lepton separation (rads)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassSameSign_lepR", "Passed SameSign Variable lepR", 0.0, 7.0, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassSameSign_lepR")->SetAxisLables("dilepton R","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassSameSign_metsig", "Passed SameSign Variable metsig", 0.0, 16.0, 32, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassSameSign_metsig")->SetAxisLables("Missing Et Significance","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassAnaCut_LepAEn", "Passed AnaCut Variable LepAEn", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassAnaCut_LepAEn")->SetAxisLables("Higher Lepton Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassAnaCut_LepBEn", "Passed AnaCut Variable LepBEn", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassAnaCut_LepBEn")->SetAxisLables("Lower Lepton Energy GeV","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassAnaCut_dilmass", "Passed AnaCut Variable dilmass", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassAnaCut_dilmass")->SetAxisLables("Dilepton Mass (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassAnaCut_metmag", "Passed AnaCut Variable metmag", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassAnaCut_metmag")->SetAxisLables("Missing Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassAnaCut_addEt", "Passed AnaCut Variable addEt", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassAnaCut_addEt")->SetAxisLables("Sum Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassAnaCut_dPhiMetLJ", "Passed AnaCut Variable dPhiMetLJ", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassAnaCut_dPhiMetLJ")->SetAxisLables("Closest object to Missing Et (rads)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassAnaCut_ntightjets", "Passed AnaCut Variable tightjets", 0.0, 10.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassAnaCut_ntightjets")->SetAxisLables("Jet Number","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassAnaCut_jet1_Et", "Passed AnaCut Variable jet1_Et", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassAnaCut_jet1_Et")->SetAxisLables("Highest Jet Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassAnaCut_jet2_Et", "Passed AnaCut Variable jet2_Et", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassAnaCut_jet2_Et")->SetAxisLables("Second Highest Jet Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassAnaCut_dildphi", "Passed AnaCut Variable dildphi", 0.0, 3.141592654, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassAnaCut_dildphi")->SetAxisLables("lepton separation (rads)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassAnaCut_lepR", "Passed AnaCut Variable lepR", 0.0, 7.0, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassAnaCut_lepR")->SetAxisLables("dilepton R","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("PassAnaCut_metsig", "Passed AnaCut Variable metsig", 0.0, 16.0, 32, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("PassAnaCut_metsig")->SetAxisLables("Missing Et Significance","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metee_LepAEn", "Nm1 Met ee Variable LepAEn", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metee_LepAEn")->SetAxisLables("Higher Lepton Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metee_LepBEn", "Nm1 Met ee Variable LepBEn", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metee_LepBEn")->SetAxisLables("Lower Lepton Energy GeV","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metee_dilmass", "Nm1 Met ee Variable dilmass", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metee_dilmass")->SetAxisLables("Dilepton Mass (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metee_metmag", "Nm1 Met ee Variable metmag", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metee_metmag")->SetAxisLables("Missing Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metee_addEt", "Nm1 Met ee Variable addEt", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metee_addEt")->SetAxisLables("Sum Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metee_dPhiMetLJ", "Nm1 Met ee Variable dPhiMetLJ", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metee_dPhiMetLJ")->SetAxisLables("Closest object to Missing Et (rads)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metee_ntightjets", "Nm1 Met ee Variable tightjets", 0.0, 10.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metee_ntightjets")->SetAxisLables("Jet Number","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metee_jet1_Et", "Nm1 Met ee Variable jet1_Et", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metee_jet1_Et")->SetAxisLables("Highest Jet Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metee_jet2_Et", "Nm1 Met ee Variable jet2_Et", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metee_jet2_Et")->SetAxisLables("Second Highest Jet Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metee_dildphi", "Nm1 Met ee Variable dildphi", 0.0, 3.141592654, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metee_dildphi")->SetAxisLables("lepton separation (rads)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metee_lepR", "Nm1 Met ee Variable lepR", 0.0, 7.0, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metee_lepR")->SetAxisLables("dilepton R","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metee_metsig", "Nm1 Met ee Variable metsig", 0.0, 16.0, 32, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metee_metsig")->SetAxisLables("Missing Et Significance","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metemu_LepAEn", "Nm1 Met emu Variable LepAEn", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metemu_LepAEn")->SetAxisLables("Higher Lepton Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metemu_LepBEn", "Nm1 Met emu Variable LepBEn", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metemu_LepBEn")->SetAxisLables("Lower Lepton Energy GeV","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metemu_dilmass", "Nm1 Met emu Variable dilmass", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metemu_dilmass")->SetAxisLables("Dilepton Mass (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metemu_metmag", "Nm1 Met emu Variable metmag", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metemu_metmag")->SetAxisLables("Missing Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metemu_addEt", "Nm1 Met emu Variable addEt", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metemu_addEt")->SetAxisLables("Sum Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metemu_dPhiMetLJ", "Nm1 Met emu Variable dPhiMetLJ", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metemu_dPhiMetLJ")->SetAxisLables("Closest object to Missing Et (rads)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metemu_ntightjets", "Nm1 Met emu Variable tightjets", 0.0, 10.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metemu_ntightjets")->SetAxisLables("Jet Number","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metemu_jet1_Et", "Nm1 Met emu Variable jet1_Et", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metemu_jet1_Et")->SetAxisLables("Highest Jet Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metemu_jet2_Et", "Nm1 Met emu Variable jet2_Et", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metemu_jet2_Et")->SetAxisLables("Second Highest Jet Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metemu_dildphi", "Nm1 Met emu Variable dildphi", 0.0, 3.141592654, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metemu_dildphi")->SetAxisLables("lepton separation (rads)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metemu_lepR", "Nm1 Met emu Variable lepR", 0.0, 7.0, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metemu_lepR")->SetAxisLables("dilepton R","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metemu_metsig", "Nm1 Met emu Variable metsig", 0.0, 16.0, 32, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metemu_metsig")->SetAxisLables("Missing Et Significance","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metmumu_LepAEn", "Nm1 Met mumu Variable LepAEn", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metmumu_LepAEn")->SetAxisLables("Higher Lepton Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metmumu_LepBEn", "Nm1 Met mumu Variable LepBEn", 0.0, 100.0, 100, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metmumu_LepBEn")->SetAxisLables("Lower Lepton Energy GeV","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metmumu_dilmass", "Nm1 Met mumu Variable dilmass", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metmumu_dilmass")->SetAxisLables("Dilepton Mass (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metmumu_metmag", "Nm1 Met mumu Variable metmag", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metmumu_metmag")->SetAxisLables("Missing Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metmumu_addEt", "Nm1 Met mumu Variable addEt", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metmumu_addEt")->SetAxisLables("Sum Et (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metmumu_dPhiMetLJ", "Nm1 Met mumu Variable dPhiMetLJ", 0.0, 3.141592654, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metmumu_dPhiMetLJ")->SetAxisLables("Closest object to Missing Et (rads)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metmumu_ntightjets", "Nm1 Met mumu Variable tightjets", 0.0, 10.0, 10, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metmumu_ntightjets")->SetAxisLables("Jet Number","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metmumu_jet1_Et", "Nm1 Met mumu Variable jet1_Et", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metmumu_jet1_Et")->SetAxisLables("Highest Jet Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metmumu_jet2_Et", "Nm1 Met mumu Variable jet2_Et", 0.0, 200.0, 40, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metmumu_jet2_Et")->SetAxisLables("Second Highest Jet Energy (GeV)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metmumu_dildphi", "Nm1 Met mumu Variable dildphi", 0.0, 3.141592654, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metmumu_dildphi")->SetAxisLables("lepton separation (rads)","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metmumu_lepR", "Nm1 Met mumu Variable lepR", 0.0, 7.0, 20, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metmumu_lepR")->SetAxisLables("dilepton R","Events"); _subAnaHists->AddAnaHist(new TDAnaHist("Nm1Metmumu_metsig", "Nm1 Met mumu Variable metsig", 0.0, 16.0, 32, _datasource.c_str(), "HistSetDesc")); _subAnaHists->GetAnaHist("Nm1Metmumu_metsig")->SetAxisLables("Missing Et Significance","Events"); //omg /*#include "AnaHistBookDYDom.cc" #include "AnaHistBookDYDomHighM.cc" #include "AnaHistBookDYDomLowM.cc" #include "AnaHistBookHWWDom.cc" #include "AnaHistBookWWDom.cc" #include "AnaHistBookWWDomMBox.cc" #include "AnaHistBookWWDomOutMBox.cc"*/ } } } } const char * GetDataSource(){return _datasource.c_str();} int HistFill(const char * histname, double fillvalue, double weight); int HistFill(const char * histname, double fillvalue, double fillvalue2, double weight); double GetDilWeight(); void DebugOut(char * statement, bool condition=true) { if(_debug && condition) std::cout<0.0) rho = (zCOT - z0) / tan(lambda); else rho = -(zCOT + z0) / tan(lambda); return rho; } TDAnaCutSet * GetAnaCutSet(){return _anaCutSet;} TDAnaCutSet * GetAnaCutSet_ee(){return _anaCutSetee;} TDAnaCutSet * GetAnaCutSet_emu(){return _anaCutSetemu;} TDAnaCutSet * GetAnaCutSet_mumu(){return _anaCutSetmumu;} void SetTomUnbinned() { _tomUnbinnedTree = new TTree("TomTree", "events passing non-MH-dependent cuts"); _tomUnbinnedTree->Branch("run", &run, "run/I"); _tomUnbinnedTree->Branch("evt", &evt, "evt/I"); _tomUnbinnedTree->Branch("metmag", _cutInterface->metmag(), "metmag/F"); _tomUnbinnedTree->Branch("addEt", _cutInterface->addEt(), "addEt/F"); _tomUnbinnedTree->Branch("dildphi", &dildphi, "dildphi/F"); _tomUnbinnedTree->Branch("dilmass", &dilmass, "dilmass/F"); // _tomUnbinnedTree->Branch("dilmass", &dilmass, "passed/I"); } void WriteTomUnbinned() { //char buffer[200]; // sprintf(buffer,"results/hists_%s-%s_%d-%d.root",_datasource.c_str(), (_dilset.GetDilString().c_str()), _weighttype, ((int)_higgsMass)); TFile* f= new TFile("results/DataUnbinned.root","recreate"); //char buffer[200]; //sprintf(buffer,"%s",(_DataSourcePrefix + "-" + _Name).c_str()); _tomUnbinnedTree->Write("",TObject::kOverwrite); f->Close(); } void SetDescVar() { _descVar = new TTree("TDDescVar", "descriminating variables"); _descVar->Branch("LepAEn", _cutInterface->LepAEn(), "LepAEn/F"); // _descVar->Branch("LepACalIsol", _cutInterface->LepACalIsol(), "LepACalIsol/F"); // _descVar->Branch("LepATrkIsol", _cutInterface->LepATrkIsol(), "LepATrkIsol/F"); _descVar->Branch("LepBEn", _cutInterface->LepBEn(), "LepBEn/F"); // _descVar->Branch("LepBCalIsol", _cutInterface->LepBCalIsol(), "LepBCalIsol/F"); // _descVar->Branch("LepBTrkIsol", _cutInterface->LepBTrkIsol(), "LepBTrkIsol/F"); _descVar->Branch("dilmass", _cutInterface->dilmass(), "dilmass/F"); // _descVar->Branch("nhjets", _cutInterface->nhjets(), "nhjets/F"); // _descVar->Branch("nmjets", _cutInterface->nmjets(), "nmjets/F"); // _descVar->Branch("nljets", _cutInterface->nljets(), "nljets/F"); _descVar->Branch("metmag", _cutInterface->metmag(), "metmag/F"); _descVar->Branch("ChargeProduct", _cutInterface->ChargeProduct(), "ChargeProduct/I"); _descVar->Branch("addEt", _cutInterface->addEt(), "addEt/F"); _descVar->Branch("dPhiMetLJ", _cutInterface->dPhiMetLJ(), "dPhiMetLJ/F"); _descVar->Branch("ntightjets", _cutInterface->ntightjets(), "ntightjets/F"); _descVar->Branch("jet1_Et", _cutInterface->jet1_Et(), "jet1_Et/F"); _descVar->Branch("jet2_Et", _cutInterface->jet2_Et(), "jet2_Et/F"); // _descVar->Branch("jet2_Et", &_datasourceint, "jet2_Et/I");//TD fix to check the correlation _descVar->Branch("weight", &weight, "weight/F"); _descVar->Branch("rand", &_myrand, "rand/F"); _descVar->Branch("type",&_datasourceint,"type/I"); _descVar->Branch("dildphi",&dildphi,"dildphi/F"); _descVar->Branch("metsig",&metsig,"metsig/F"); _descVar->Branch("lepR",&_lepR,"lepR/F"); _descVar->Branch("diltype",&_NNdiltype,"diltype/F"); _descVar->Branch("Mt_ll", &_Mt_ll, "Mt_ll/F"); _descVar->Branch("Mt_llMet", &_Mt_llMet, "Mt_llMet/F"); _descVar->Branch("Mt_All", &_Mt_All, "Mt_All/F"); _descVar->Branch("Isr", &_Isr, "Isr/F"); _descVar->Branch("DilPhillCorr",&_DilPhillCorr, "DilPhillCorr/F"); _descVar->Branch("run", &run, "run/I"); _descVar->Branch("evt", &evt, "evt/I"); // _descVar->Branch("",&,"/F"); _descVar2 = new TTree("TDDescVar2", "descriminating variables"); _descVar2->Branch("LepAEn", _cutInterface->LepAEn(), "LepAEn/F"); // _descVar2->Branch("LepACalIsol", _cutInterface->LepACalIsol(), "LepACalIsol/F"); // _descVar2->Branch("LepATrkIsol", _cutInterface->LepATrkIsol(), "LepATrkIsol/F"); _descVar2->Branch("LepBEn", _cutInterface->LepBEn(), "LepBEn/F"); // _descVar2->Branch("LepBCalIsol", _cutInterface->LepBCalIsol(), "LepBCalIsol/F"); // _descVar2->Branch("LepBTrkIsol", _cutInterface->LepBTrkIsol(), "LepBTrkIsol/F"); _descVar2->Branch("dilmass", _cutInterface->dilmass(), "dilmass/F"); // _descVar2->Branch("nhjets", _cutInterface->nhjets(), "nhjets/F"); // _descVar2->Branch("nmjets", _cutInterface->nmjets(), "nmjets/F"); // _descVar2->Branch("nljets", _cutInterface->nljets(), "nljets/F"); _descVar2->Branch("metmag", _cutInterface->metmag(), "metmag/F"); _descVar2->Branch("ChargeProduct", _cutInterface->ChargeProduct(), "ChargeProduct/I"); _descVar2->Branch("addEt", _cutInterface->addEt(), "addEt/F"); _descVar2->Branch("dPhiMetLJ", _cutInterface->dPhiMetLJ(), "dPhiMetLJ/F"); _descVar2->Branch("ntightjets", _cutInterface->ntightjets(), "ntightjets/F"); _descVar2->Branch("jet1_Et", _cutInterface->jet1_Et(), "jet1_Et/F"); _descVar2->Branch("jet2_Et", _cutInterface->jet2_Et(), "jet2_Et/F"); // _descVar2->Branch("jet2_Et", &_datasourceint, "jet2_Et/I");//TD fix to check the correlation _descVar2->Branch("weight", &weight, "weight/F"); _descVar2->Branch("rand", &_myrand, "rand/F"); _descVar2->Branch("type",&_datasourceint,"type/I"); _descVar2->Branch("dildphi",&dildphi,"dildphi/F"); _descVar2->Branch("metsig",&metsig,"metsig/F"); _descVar2->Branch("lepR",&_lepR,"lepR/F"); _descVar2->Branch("diltype",&_NNdiltype,"diltype/F");//TD only whether or not there are the same type of leptons (DY has ony same type) _descVar2->Branch("Mt_ll", &_Mt_ll, "Mt_ll/F"); _descVar2->Branch("Mt_llMet", &_Mt_llMet, "Mt_llMet/F"); _descVar2->Branch("Mt_All", &_Mt_All, "Mt_All/F"); _descVar2->Branch("Isr", &_Isr, "Isr/F"); _descVar2->Branch("DilPhillCorr",&_DilPhillCorr, "DilPhillCorr/F"); _descVar2->Branch("run", &run, "run/I"); _descVar2->Branch("evt", &evt, "evt/I"); if(_SaveRjn)_rootJetNetfile<<"LepAEn"<& Getalldilcuts(){return _alldilcuts;} TDRunInfoSet& GetRunInfoSet(){return _sampleRunInfo;} TDRunInfo GetRunInfo(){return _sampleRunInfo.GetSumTDRunInfo();} double GetInputEvents(){return _genNum;}//TD worked out differtently!!!!! double GetInputEvents0d(){return _genNum0d;}//TD quick ifxes - should really take a runrange as an arguement. double GetInputEvents0h(){return _genNum0h;} double GetInputEvents0i(){return _genNum0i;} //double GetInputEvents_ee(){return _genNum_ee;}//TD returns wrong value if end ana has not been called // double GetInputEvents_emu(){return _genNum_emu;}//TD returns wrong value if end ana has not been called // double GetInputEvents_mumu(){return _genNum_mumu;}//TD returns wrong value if end ana has not been called double GetEff_ee(){return _eff_ee;} double GetEff_emu(){return _eff_emu;} double GetEff_mumu(){return _eff_mumu;} void SetInputEvents(int gennum){_genNum=gennum;} double GetInputEvents(TDRunSet& set){return _sampleRunInfo.GetSumTDRunInfo(set)._hepgZ;} double GetInputEvents(DilType::dilepton_type thedilType) {if(_stn)return _sampleRunInfo.GetSumTDRunInfo(*(_hwwlvlvGoodRun17.GetRunSet(thedilType)))._hepgZ; return _sampleRunInfo.GetSumTDRunInfo(*(_hwwlvlvGoodRun.GetRunSet(thedilType)))._hepgZ;} double GetInputEvents(int thedilType)//TD worked out differtently!!!!! { return _dilGenNum[thedilType]; } //{if(_stn)return _sampleRunInfo.GetSumTDRunInfo(*(_hwwlvlvGoodRun13.GetRunSet(_dilType.Int2Type(thedilType))))._hepgZ; // return _sampleRunInfo.GetSumTDRunInfo(*(_hwwlvlvGoodRun.GetRunSet(_dilType.Int2Type(thedilType))))._hepgZ;} double GetGoodGenMassZ(){return _sampleRunInfo.GetSumTDRunInfo()._goodZ;} double GetGoodGenMassZ(TDRunSet& set){return _sampleRunInfo.GetSumTDRunInfo(set)._goodZ;} double GetGoodGenMassZ(DilType::dilepton_type thedilType) {if(_stn)return _sampleRunInfo.GetSumTDRunInfo(*(_hwwlvlvGoodRun17.GetRunSet(thedilType)))._goodZ; return _sampleRunInfo.GetSumTDRunInfo(*(_hwwlvlvGoodRun.GetRunSet(thedilType)))._goodZ;} double GetGoodGenMassZ(int thedilType) {if(_stn)return _sampleRunInfo.GetSumTDRunInfo(*(_hwwlvlvGoodRun17.GetRunSet(_dilType.Int2Type(thedilType))))._goodZ; return _sampleRunInfo.GetSumTDRunInfo(*(_hwwlvlvGoodRun.GetRunSet(_dilType.Int2Type(thedilType))))._goodZ;} double GetGoodGenZ(){return _goodZGenNum;} //TD worked out differtently!!!!! double GetGoodGenZ(TDRunSet& set){return _sampleRunInfo.GetSumTDRunInfo(set)._goodobsp;} double GetGoodGenZ(DilType::dilepton_type thedilType) {if(_stn)return _sampleRunInfo.GetSumTDRunInfo(*(_hwwlvlvGoodRun17.GetRunSet(thedilType)))._goodobsp; return _sampleRunInfo.GetSumTDRunInfo(*(_hwwlvlvGoodRun.GetRunSet(thedilType)))._goodobsp;} double GetGoodGenZ(int thedilType) { return _goodZDilGenNum[thedilType]; } std::vector GetGoodZDileptonVector(){return _alldilGoodZ;} double GetGoodZDilepton(DilType::dilepton_type thedilType){return _alldilGoodZ[thedilType];} double GetGoodZDilepton(int thedilType){return _alldilGoodZ[thedilType];} double GetGoodZ(){return _totZevents;} std::vector GetGoodZDileptonVector_mycut(){return _alldilGoodZ_mycut;} double GetGoodZDilepton_mycut(DilType::dilepton_type thedilType){return _alldilGoodZ_mycut[thedilType];} double GetGoodZDilepton_mycut(int thedilType){return _alldilGoodZ_mycut[thedilType];} //double GetGoodZ_mycut(){return _totZevents_mycut;} std::vector GetSSDileptonVector_mycut(){return _alldilSS_mycut;} double GetSSDilepton_mycut(int thedilType){return _alldilSS_mycut[thedilType];} std::vector GetGoodZDileptonVector_1020cut(){return _alldilGoodZ_1020cut;} double GetGoodZDilepton_1020cut(DilType::dilepton_type thedilType){return _alldilGoodZ_1020cut[thedilType];} double GetGoodZDilepton_1020cut(int thedilType){return _alldilGoodZ_1020cut[thedilType];} std::vector GetSSDileptonVector_1020cut(){return _alldilSS_1020cut;} double GetSSDilepton_1020cut(int thedilType){return _alldilSS_1020cut[thedilType];} int GetFailGoodRun(int thedilType){return _failgoodrun[thedilType];} int GetFailExtraGoodRun(int thedilType){return _failextragoodrun[thedilType];} int GetRawDilNumber(int thedilType){return _rawDilNumber[thedilType];} int GetDataSourceInt(){return _datasourceint;} std::vector GetSSDileptonVector(){return _alldilSS;} double GetSSDilepton(int thedilType) { if(thedilType>DilType::CMX_CMIO) { std::cout<<"out of range"<GetAnaHist("luminosity")->GetHist()->GetMean();} double DeanDetEta(double const eta, double const z0); std::vector GetGoodWW(){return _goodWW;} double GetGoodWW(int diltype){return _goodWW[diltype];} double GetTotGoodWW(){return _totWW;} float GetXS() { double xstoreturn=_xs; //new DY does not need this factor //if(_datasource!="Ztautau")xstoreturn=_xs; //else xstoreturn=_xs*( // ((float)(GetInputEvents()-GetInputEvents0h()-GetInputEvents0i())/(float)GetInputEvents()) // +0.67*(((float)GetInputEvents0h()+GetInputEvents0i())/(float)GetInputEvents()) // ); if(_removeNNtrain && _datasource=="higgsww")xstoreturn/=(0.5); if(_removeNNtrain && _datasource=="WW")xstoreturn/=(1.0-0.504); //for test and train - taking out all the test and train events and leaving the others if(_removeNNtrain && (_datasource=="Ztautau" || _datasource=="Zmumu" || _datasource=="Zee"))xstoreturn/=(1.0-0.099); //for test and train - taking out all the test and train events and leaving the others return xstoreturn; } float GetScaleforNormalisation(){if(isData())return 1;//std::cout<<"lum: "<<_alldilLums[0]<); void RedoAxisLables(); void GetPDFError(bool, char*, char*, char*); double GetEtCutEff(int cut){ if(cut>=1 && cut<=3) { return _passEtcut[cut]/_passEtcut[0]; }else{ std::cout<<"missing et cut out of range in GetEtCutEff"<=1 && cut<=3) { return sqrt((1.0/_passEtcut[cut])+(1.0/_passEtcut[0])); }else{ std::cout<<"missing et cut out of range in GetEtCutEffError"<=0 && cut<=3) { std::cout<<"GetEtCutEffVal cut:"<=0 && cut<=6) { std::cout<<"GetEtCutEffVal cut:"<=0 && cut<=3) { //std::cout<<"GetNNDYCutEffVal cut:"< _uniqueEvents; std::vector _alldilcuts; std::vector _alldilcuts_0d; std::vector _alldilcuts_0h; std::vector _alldilcuts_0i; std::vector _alldilcuts_0h0i; std::vector _allNNdilcuts; std::vector _allNNdilcuts_0d; std::vector _allNNdilcuts_0h; std::vector _allNNdilcuts_0i; std::vector _allNNdilcuts_0h0i; TDRunInfoSet _sampleRunInfo; double _totZevents; double _totSS; double _totWW; std::vector _alldilGoodZ; std::vector _alldilSS; std::vector _alldilGoodZ_mycut; std::vector _alldilSS_mycut; std::vector _alldilGoodZ_1020cut; std::vector _alldilSS_1020cut; std::vector _alldilLums; std::vector _alldilLums_sexo; std::vector _alldilCMXratio; std::vector _alldilCMXprescaled; std::vector _alldilCMXnonprescaled; std::vector _goodWW; std::vector _failgoodrun; std::vector _failextragoodrun; std::vector _rawDilNumber; //TDRunInfoSet _sampleRunInfo; std::vector _dilGenNum; //it seems with some root files, this has problems deleting itself, probably due to memory over run. //TDRunInfoSet _debugrunevt; std::vector _goodZDilGenNum; std::vector _sexoweights; std::vector _deancomp_fakenumbers; std::vector _deancomp_fakes; std::vector _Dil_Gen6_MC_vs_data_lumscale; float _Gen6_MC_vs_data_lumscale; //std::vector _alldildumps; float _higgsMass; std::ofstream& _cutblockLat; TTree * _descVar; TTree * _descVar2; //bool _descVarSet; TDHistSet _dileptonmasshists; //int _color; TDRunSet _debugruns; TTree * _tomUnbinnedTree; int _minRun; int _maxRun; TDRunInfoSet _debugrunevt; TDUniqueMap _debugEvents; int _datasourceint; float weight; float rawweight; float luminosityweight; float gennumberweight; float goodZweight; float _myrand; float _myrand2; TRandom _random; std::ofstream _rootJetNetfile; bool _stn; int _genNum; int _genNum0d; int _genNum0h; int _genNum0i; int _genNum_sexo; int _goodZGenNum; int _badCMXRCot; int _badCMXWedge; bool _mircea; float _xs; // int dilep1020; float _lowestlumback; // --------------------------------------------------------------- // choose MVA methods to be trained + tested bool Use_Cuts; bool Use_Likelihood; bool Use_LikelihoodD; bool Use_PDERS; bool Use_HMatrix; bool Use_Fisher; bool Use_CFMlpANN; bool Use_TMlpANN; bool Use_BDT;//_GiniIndex; // default BDT method //bool Use_BDT_CrossEntro; //bool Use_BDT_SdivStSpB; //bool Use_BDT_MisClass; //bool Use_BDT_Bagging_Gini; // --------------------------------------------------------------- bool EvaluateVariables; // perform evaluation for each input variable // --------------------------------------------------------------- // TMVA::Reader *reader; vector* inputVars; //TMVA::Reader *reader2; TMVA::Reader *reader_ee; TMVA::Reader *reader2_ee; TMVA::Reader *reader_emu; TMVA::Reader *reader2_emu; TMVA::Reader *reader_mumu; TMVA::Reader *reader2_mumu; bool initTMVA; float _lepR; float _NNdiltype; TMultiLayerPerceptron * _myNN; bool _initTMLP; TH1F * _ISRHist; TH1F * _ISRHistUp; TH1F * _ISRHistDn; //DFakeRates _fakes; bool _initFakes; std::vector * _fakevectord; std::vector * _fakevectorh; std::vector * _fakevectori; int _matTest; bool _SaveRjn; bool _useSCMIO; float _Mt_ll; float _Mt_llMet; float _Mt_All; float _Isr; float _DilPhillCorr; bool _saveNN; double _passEtcut[4]; //[0] for total ammount; [1] that pass 20GeV missing Et; [2], 30; [3], 40 GeV cut. double _passNNDYcut[4]; //[0] for total amount; [1] str1; [2] str2; [3] str3. double _metsigcuts[6]; //[0] for total ammount; [1]-my metsig cut; [2]-dean metsig cut; [3]-dean metsigcut 2020; [4]-metspecial cut; [5] metspecial cut mll>25. double _deancomp_metsig[3][4]; // [number, weighted number, fake weighted number] // double _genNum_ee; // double _genNum_emu; // double _genNum_mumu; double _eff_ee; double _eff_emu; double _eff_mumu; int _this_runs_events; int _fakeevent; int _normalevent; bool _wgammaerr; bool _sexo; bool _sexocombined; bool _drawhists; int _checknum1; int _checknum2; bool _drawNNhists; bool _drawNNhists2; bool _drawNNhists3; bool _drawNNhists4; bool _drawNNhists5; bool _passNNDY; float _isolcut; int _7708Cutrejection; double _specialmet; double _specialmetsig; bool _extraDYpass; bool _removeNNtrain; int _removeNNtrain_counter_0; int _removeNNtrain_counter_1; int _removeNNtrain_counter_2; bool _sexocomb_nat; TDRunInfoSet _cmx_lum; TDRunInfoSet _noncmx_lum; //TProfile _hprof;// = new TProfile("hprof","Profile of pz versus px",100,0,200,0,200); int _runint[27]; double _epsvtxvals[26]; int _nevents_for_vtxcalc; double _total_vtx_corr; int _maxrunfromZlog; std::string _fileLocation; TDStandardPlots _histsDYDom; TDStandardPlots _histsDYDomHighM; TDStandardPlots _histsDYDomLowM; TDStandardPlots _histsHWWDom; TDStandardPlots _histsWWDom; TDStandardPlots _histsWWDomMBox; TDStandardPlots _histsWWDomOutMBox; TDStandardPlots _histsNNDYCut; TDStandardPlots _histsLepEtControlNNDYCut; TDStandardPlots _histsNNInputVar; TDStandardPlots _histsLepEtControlNNInputVar; TDStandardPlots _histsHighMllControlNNInputVar; TDStandardPlots _histsHighMllControlNNDYCut; TDStandardPlots _histsZPeakNNInputVar; TDStandardPlots _histsZPeakNNDYCut; //hists3 TDStandardPlots _histsWWNNlowCut; TDStandardPlots _histsWWNNmidCut; TDStandardPlots _histsWWNNhighCut; //hists4 TDStandardPlots _histsNNDYCutMid; TDStandardPlots _histsLowMllControlNNInputVar; TDStandardPlots _histsLowMllControlNNDYCut; TDMassPlots _zmass_mass; TDMassPlots _zmass_040mass; TDMassPlots _zmass_fullmass; TDDilplots _rawweightplots; TDDilplots _relweighterrorplots; TDDilplots _weightplots; //hists5 TDStandardPlots _histsLMetHMetSNNInputVar; TDStandardPlots _histsLMetSHMetNNInputVar; }; #endif