241 |
|
else |
242 |
|
assert(0); |
243 |
|
} |
244 |
– |
if(isMC_){ |
245 |
– |
if (dataset_=="Summer12_DR53X_HCP2012") { |
246 |
– |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())<1 && ele->SCluster()->R9()<0.94) dsigMC = 0.0103; |
247 |
– |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())<1 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0090; |
248 |
– |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())>=1 && ele->SCluster()->R9()<0.94) dsigMC = 0.0190; |
249 |
– |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())>=1 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0156; |
250 |
– |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())<2 && ele->SCluster()->R9()<0.94) dsigMC = 0.0269; |
251 |
– |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())<2 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0287; |
252 |
– |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())>=2 && ele->SCluster()->R9()<0.94) dsigMC = 0.0364; |
253 |
– |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())>=2 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0321; |
254 |
– |
} |
255 |
– |
else if (dataset_=="Fall11") { // values from https://hypernews.cern.ch/HyperNews/CMS/get/higgs2g/634.html, consistant with Jan16ReReco corrections |
256 |
– |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())<1 && ele->SCluster()->R9()<0.94) dsigMC = 0.0096; |
257 |
– |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())<1 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0074; |
258 |
– |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())>=1 && ele->SCluster()->R9()<0.94) dsigMC = 0.0196; |
259 |
– |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())>=1 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0141; |
260 |
– |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())<2 && ele->SCluster()->R9()<0.94) dsigMC = 0.0279; |
261 |
– |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())<2 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0268; |
262 |
– |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())>=2 && ele->SCluster()->R9()<0.94) dsigMC = 0.0301; |
263 |
– |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())>=2 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0293; |
264 |
– |
} |
244 |
|
|
245 |
< |
else |
246 |
< |
assert(0); |
245 |
> |
if (dataset_=="Summer12_DR53X_HCP2012" || dataset_ == "2012Jul13ReReco") { |
246 |
> |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())<1 && ele->SCluster()->R9()<0.94) dsigMC = 0.0103; |
247 |
> |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())<1 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0090; |
248 |
> |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())>=1 && ele->SCluster()->R9()<0.94) dsigMC = 0.0190; |
249 |
> |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())>=1 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0156; |
250 |
> |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())<2 && ele->SCluster()->R9()<0.94) dsigMC = 0.0269; |
251 |
> |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())<2 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0287; |
252 |
> |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())>=2 && ele->SCluster()->R9()<0.94) dsigMC = 0.0364; |
253 |
> |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())>=2 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0321; |
254 |
|
} |
255 |
+ |
else if (dataset_=="Fall11" ||dataset_ == "Jan16ReReco") { // values from https://hypernews.cern.ch/HyperNews/CMS/get/higgs2g/634.html, consistant with Jan16ReReco corrections |
256 |
+ |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())<1 && ele->SCluster()->R9()<0.94) dsigMC = 0.0096; |
257 |
+ |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())<1 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0074; |
258 |
+ |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())>=1 && ele->SCluster()->R9()<0.94) dsigMC = 0.0196; |
259 |
+ |
if (ele->IsEB() && fabs(ele->SCluster()->Eta())>=1 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0141; |
260 |
+ |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())<2 && ele->SCluster()->R9()<0.94) dsigMC = 0.0279; |
261 |
+ |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())<2 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0268; |
262 |
+ |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())>=2 && ele->SCluster()->R9()<0.94) dsigMC = 0.0301; |
263 |
+ |
if (ele->IsEE() && fabs(ele->SCluster()->Eta())>=2 && ele->SCluster()->R9()>=0.94) dsigMC = 0.0293; |
264 |
+ |
} |
265 |
+ |
else |
266 |
+ |
assert(!isMC_); |
267 |
|
|
268 |
|
float corrected_energy = -999; |
269 |
|
|
270 |
|
if (!isMC_){ |
271 |
|
if(dataset_ == "Jan16ReReco") corrected_energy = energy/(1+corr); |
272 |
< |
else if (!isMC_ && dataset_ == "2012Jul13ReReco") corrected_energy = energy*scale; |
272 |
> |
else if (dataset_ == "2012Jul13ReReco") corrected_energy = energy*scale; |
273 |
|
else assert(0); |
274 |
|
} |
275 |
|
if (isMC_) { |