234 |
|
if(addcut!="") kbase=kbase&&addcut.c_str();//this is mostly for SUSY scans (adding requirements on masses) |
235 |
|
// Corresponding reco. cuts |
236 |
|
TCut ksel("pfJetGoodNum>2&&abs(mll-91.2)<20&&id1==id2&&"+TString(mcjzb)+geq_or_leq()+TString(jzbSelStr)); |
237 |
< |
TCut ksel2("pfJetGoodNum>2&&abs(mll-91.2)<20&&id1==id2&&"+TString(mcjzb)+ngeq_or_leq()+TString(jzbSelStr)); |
237 |
> |
TCut ksel2("pfJetGoodNum>2&&abs(mll-91.2)<20&&id1==id2&&"+TString(mcjzb)+ngeq_or_leq()+TString("-")+TString(jzbSelStr)); |
238 |
|
events->Draw(mcjzbexpression.c_str(),kbase&&ksel,"goff"); |
239 |
|
Float_t sel = events->GetSelectedRows(); |
240 |
|
events->Draw(mcjzbexpression.c_str(),kbase&&ksel2,"goff"); |
245 |
|
|
246 |
|
result=(sel-nsel)/tot; |
247 |
|
resulterr=TMath::Sqrt(sel/tot*(1-sel/tot)/tot); |
248 |
< |
if(!automatized) dout << " MC efficiency: " << result << "+-" << resulterr << std::endl; |
248 |
> |
dout << " MC efficiency: " << result << "+-" << resulterr << " ( JZB>" << jzbSel << " : " << sel << " , JZB<-" << jzbSel << " : " << nsel << " and nevents=" << tot << ")" << std::endl; |
249 |
|
} |
250 |
|
|
251 |
|
void JZBefficiency(TTree *events, string informalname, float &jzbeff, float &jzbefferr, bool requireZ, string addcut="") { |