本文整理汇总了C++中Events::set_sf方法的典型用法代码示例。如果您正苦于以下问题:C++ Events::set_sf方法的具体用法?C++ Events::set_sf怎么用?C++ Events::set_sf使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Events
的用法示例。
在下文中一共展示了Events::set_sf方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: plotHistos_Wen
//.........这里部分代码省略.........
TCut mc_trigger = "";
TCut data_trigger = "";
TCut cutdata_all = cutmc_all;
cutdata_all += data_trigger;
cutmc_all += mc_trigger;
// Scale factors in order of: WjLF, WjHF, ZjLF, ZjHF, TT
// NOTE: ZjLF, ZjHF are not needed for Wln
double scalefactors[5] = {1.00, 1.00, 1.00, 1.00, 1.00};
// Znn______________________________________________________________________
//TString channel = "Znn";
// These are loose cuts for all plots in this particular channel
//TCut cutmc_all = "Vtype==4 && HCSV_pt>130 && Jet_pt[hJCidx[0]]>80 && Jet_pt[hJCidx[1]]>30 && abs(Jet_eta[hJCidx[0]])<2.5 && abs(Jet_eta[hJCidx[1]])<2.5 && naLeptons==0 && Sum$(Jet_pt > 20 & abs(Jet_eta) < 2.4)<5";
//&& min(Min$(abs(deltaPhi(met_phi,hJet_phi))),Min$(abs(deltaPhiMETjets(met_phi,aJet_phi,aJet_pt,aJet_eta)))+999*(Sum$(aJet_pt>25 && abs(aJet_eta)<4.5 && aJet_id==1 && aJet_puJetIdL>0)==0) )>0.5";//needs to be updated to 13 TeV
//cutmc_all += "min(Jet_btagCSV[hJCidx[0]], Jet_btagCSV[hJCidx[1]])>0.4 && min(abs(HCSV_phi-V_phi),(2*TMath::Pi())-abs(HCSV_phi-V_phi))>2.0"; // tighter cut
//TCut cutdata_all = cutmc_all;
//cutmc_all *= "(triggerFlags[42]==1 || triggerFlags[39]==1 || triggerFlags[41]==1)"; // apply trigger bits and MET cleaning for MC (they are already applied on data)
//cutmc_all *= "triggercorrMET(met_pt)";
// Scale factors in order of: WjLF, WjHF, ZjLF, ZjHF, TT
//double scalefactors[5] = {1.00, 1.00, 1.00, 1.00, 1.00};
// All channels_____________________________________________________________
// Read from ntuples
Events * ev = new Events();
ev->read(cutmc_all, cutdata_all);
// Set the scale factors
ev->set_sf(scalefactors);
// Optimize these five variables (default: recommendations for Zll)
//double vpt = 150.;
//double hpt = 0.;
//double maxcsv = 0.679;
//double mincsv = 0.5;
//double dPhi = 0.;
// Optimize these five variables (default: recommendations for Wln)
double vpt = 150.;
double hpt = 100.;
double maxcsv = 0.898;
double mincsv = 0.5;
double dPhi = 2.95;
// Optimize these five variables (default: recommendations for Znn)
//double vpt = 170.; // for Znn, pT(V) = MET
//double hpt = 170.;
//double maxcsv = 0.898;
//double mincsv = 0.5;
//double dPhi = 2.95;
// If doing cut and count analysis, cut on HCSV_mass by changing the values of minhmass and maxhmass
//double minhmass = 0.;
//double maxhmass = 9999.;
double minhmass = 110.;
double maxhmass = 140.;
// These are tight cuts for this particular plot
//TCut cutmc = Form("V_pt>%.2f && HCSV_pt>%.2f && max(Jet_btagCSV[hJCidx[0]],Jet_btagCSV[hJCidx[1]])>%.3f && min(Jet_btagCSV[hJCidx[0]], Jet_btagCSV[hJCidx[1]])>%.3f && HVdPhi>%.2f && %.2f<HCSV_mass && HCSV_mass<%.2f", vpt, hpt, maxcsv, mincsv, dPhi, minhmass, maxhmass);
TCut cutmc = "";
TCut cutdata = cutmc;