ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/cbrown/AnalysisFramework/Plotting/Modules/ResultModule.C
(Generate patch)

Comparing UserCode/cbrown/AnalysisFramework/Plotting/Modules/ResultModule.C (file contents):
Revision 1.17 by buchmann, Mon Nov 7 11:21:51 2011 UTC vs.
Revision 1.18 by buchmann, Wed Nov 23 15:35:10 2011 UTC

# Line 256 | Line 256 | vector<float> get_result_between_two_fix
256      ftotprederr+=fstaterr*fstaterr;
257      ftotprederr=TMath::Sqrt(ftotprederr);
258      flippedNprederr.push_back(ftotprederr);
259 +    
260 +    //also save results (for data only!) in the new Results Library class
261 +    int jzbcutindex=allresults.Find(cut);
262 +      
263 +    (allresults.predictions[jzbcutindex]).Zbkg.value=zossfn;
264 +    (allresults.predictions[jzbcutindex]).Zbkg.syserror=zossfn*zjetsestimateuncert;
265 +    (allresults.predictions[jzbcutindex]).Zbkg.staterror=TMath::Sqrt(zossfn);
266 +      
267 +    float ofsyserr=0;
268 +    if(PlottingSetup::RestrictToMassPeak) {
269 +      ofsyserr+= ((zosofn)*(zosofn))*(1.0/9)*emuncert*emuncert;//sys err from emu method
270 +      ofsyserr+= ((sbossfp)*(sbossfp)+(sbossfn)*(sbossfn))*(1.0/9)*eemmsidebanduncert*eemmsidebanduncert; // sys err from eemm sidebands
271 +      ofsyserr+= ((sbosofp)*(sbosofp)+(sbosofn)*(sbosofn))*(1.0/9)*emsidebanduncert*emsidebanduncert; // sys err from emu sidebands
272 +      
273 +      (allresults.predictions[jzbcutindex]).Flavorsym.value=(1.0/3)*(zosofp-zosofn)+ (1.0/3)*(sbossfp-sbossfn)+ (1.0/3)*(sbosofp-sbosofn);
274 +      (allresults.predictions[jzbcutindex]).Flavorsym.syserror=TMath::Sqrt(ofsyserr);
275 +      (allresults.predictions[jzbcutindex]).Flavorsym.staterror=TMath::Sqrt((1.0/9)*(zosofp+zosofn)+ (1.0/9)*(sbossfp+sbossfn)+ (1.0/9)*(sbosofp+sbosofn));
276 +    } else {
277 +      ofsyserr= ((zosofn)*(zosofn))*emuncert*emuncert;//sys err from emu method
278 +      
279 +      (allresults.predictions[jzbcutindex]).Flavorsym.value=(zosofp-zosofn);
280 +      (allresults.predictions[jzbcutindex]).Flavorsym.syserror=TMath::Sqrt(ofsyserr);
281 +      (allresults.predictions[jzbcutindex]).Flavorsym.staterror=TMath::Sqrt((zosofp+zosofn));
282 +    }
283 +    
284 +    (allresults.predictions[jzbcutindex]).total.value=(allresults.predictions[jzbcutindex]).Zbkg.value+(allresults.predictions[jzbcutindex]).Flavorsym.value;
285 +    (allresults.predictions[jzbcutindex]).total.syserror=syserr;
286 +    (allresults.predictions[jzbcutindex]).total.staterror=staterr;
287 +    
288 +    (allresults.predictions[jzbcutindex]).observed.ee=zossfpee;
289 +    (allresults.predictions[jzbcutindex]).observed.mm=zossfpmm;
290 +    (allresults.predictions[jzbcutindex]).observed.eemm=zossfp;
291 +    
292 +    vector<float> sigmas = compute_one_upper_limit(1.0,0.0, Npred.size()-1, mcjzb, "UPPERLIMIT", false, 0);
293 +    
294 +    (allresults.predictions[jzbcutindex]).UpperLimit=sigmas[0];
295    }
296 +
297    vector<float> resultvector; // only used for poisson computation in experimental module (therefore ignoring flipped business)
298    flag_this_change(__FUNCTION__,__LINE__,true);//PlottingSetup::RestrictToMassPeak
299    if(PlottingSetup::RestrictToMassPeak) resultvector.push_back(zossfn + (1.0/3)*(zosofp-zosofn)+ (1.0/3)*(sbossfp-sbossfn)+ (1.0/3)*(sbosofp-sbosofn));

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines