[Rivet-svn] rivet: fix ratio of Njet bins in ATLAS_2012_I1083318

Rivet Mercurial rivet at projects.hepforge.org
Thu Mar 8 15:00:01 GMT 2018


details:   https://rivet.hepforge.org/hg/rivet/rev/8cb5b4e4d068
branches:  release-2-6-x
changeset: 6250:8cb5b4e4d068
user:      Christian Gutschow <chris.g at cern.ch>
date:      Thu Mar 08 14:35:55 2018 +0000
description:
fix ratio of Njet bins in ATLAS_2012_I1083318

diffs (18 lines):

--- a/analyses/pluginATLAS/ATLAS_2012_I1083318.cc	Wed Mar 07 11:18:28 2018 +0000
+++ b/analyses/pluginATLAS/ATLAS_2012_I1083318.cc	Thu Mar 08 14:35:55 2018 +0000
@@ -172,9 +172,12 @@
         for (size_t n = 1; n < _h_NjetIncl[i]->numBins(); ++n) {
           YODA::HistoBin1D& b0 = _h_NjetIncl[i]->bin(n-1);
           YODA::HistoBin1D& b1 = _h_NjetIncl[i]->bin(n);
-          if (b0.height() == 0.0 || b1.height() == 0.0) continue;
-          _h_RatioNjetIncl[i]->addPoint(n, b1.height()/b0.height(), 0.5,
-                                        b1.height()/b0.height() * (b0.relErr() + b1.relErr()));
+          double val = 0.0, err= 0.0;
+          if (b0.height() && b1.height()) {
+            val = b1.height() / b0.height();
+            err = b1.height() / b0.height() * (b0.relErr() + b1.relErr());
+          }
+          _h_RatioNjetIncl[i]->addPoint(n, val, 0.5, err);
         }
 
         // Scale all histos to the cross section


More information about the Rivet-svn mailing list