[Rivet-svn] r3213 - branches/2011-07-aida2yoda/src/Analyses

blackhole at projects.hepforge.org blackhole at projects.hepforge.org
Tue Jul 19 16:58:16 BST 2011


Author: dgrell
Date: Tue Jul 19 16:58:15 2011
New Revision: 3213

Log:
more analyses

Modified:
   branches/2011-07-aida2yoda/src/Analyses/ALEPH_1996_S3486095.cc
   branches/2011-07-aida2yoda/src/Analyses/ATLAS_2010_S8894728.cc
   branches/2011-07-aida2yoda/src/Analyses/ATLAS_2010_S8994773.cc
   branches/2011-07-aida2yoda/src/Analyses/ATLAS_2011_S9002537.cc
   branches/2011-07-aida2yoda/src/Analyses/CDF_1994_S2952106.cc
   branches/2011-07-aida2yoda/src/Analyses/CDF_2001_S4751469.cc
   branches/2011-07-aida2yoda/src/Analyses/CDF_2005_S6217184.cc
   branches/2011-07-aida2yoda/src/Analyses/CDF_2008_S7541902.cc
   branches/2011-07-aida2yoda/src/Analyses/CDF_2008_S7782535.cc
   branches/2011-07-aida2yoda/src/Analyses/D0_2001_S4674421.cc
   branches/2011-07-aida2yoda/src/Analyses/D0_2008_S6879055.cc
   branches/2011-07-aida2yoda/src/Analyses/DELPHI_1996_S3430090.cc
   branches/2011-07-aida2yoda/src/Analyses/DELPHI_2002_069_CONF_603.cc
   branches/2011-07-aida2yoda/src/Analyses/Makefile.am
   branches/2011-07-aida2yoda/src/Analyses/OPAL_1998_S3780481.cc
   branches/2011-07-aida2yoda/src/Analyses/UA1_1990_S2044935.cc
   branches/2011-07-aida2yoda/src/Analyses/UA5_1982_S875503.cc
   branches/2011-07-aida2yoda/src/Analyses/UA5_1987_S1640666.cc
   branches/2011-07-aida2yoda/src/Analyses/UA5_1988_S1867512.cc
   branches/2011-07-aida2yoda/src/Analyses/UA5_1989_S1926373.cc

Modified: branches/2011-07-aida2yoda/src/Analyses/ALEPH_1996_S3486095.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/ALEPH_1996_S3486095.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/ALEPH_1996_S3486095.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -234,11 +234,11 @@
 
       _histChMult->fill(numParticles, weight);
 
-      _histMeanChMultRapt05->fill(_histMeanChMultRapt05->binMean(0), rapt05 * weight);
-      _histMeanChMultRapt10->fill(_histMeanChMultRapt10->binMean(0), rapt10 * weight);
-      _histMeanChMultRapt15->fill(_histMeanChMultRapt15->binMean(0), rapt15 * weight);
-      _histMeanChMultRapt20->fill(_histMeanChMultRapt20->binMean(0), rapt20 * weight);
-      _histMeanChMult->fill(_histMeanChMult->binMean(0), numParticles*weight);
+      _histMeanChMultRapt05->fill(_histMeanChMultRapt05->bin(0).xMean(), rapt05 * weight);
+      _histMeanChMultRapt10->fill(_histMeanChMultRapt10->bin(0).xMean(), rapt10 * weight);
+      _histMeanChMultRapt15->fill(_histMeanChMultRapt15->bin(0).xMean(), rapt15 * weight);
+      _histMeanChMultRapt20->fill(_histMeanChMultRapt20->bin(0).xMean(), rapt20 * weight);
+      _histMeanChMult->fill(_histMeanChMult->bin(0).xMean(), numParticles*weight);
 
 
       //// Final state of unstable particles to get particle spectra
@@ -272,70 +272,70 @@
               break;
            case 111:
               _histMultiPi0->fill(scaledMom, weight);
-              _histMeanMultiPi0->fill(_histMeanMultiPi0->binMean(0), weight);
+              _histMeanMultiPi0->fill(_histMeanMultiPi0->bin(0).xMean(), weight);
               _weightedTotalNumPi0 += weight;
               break;
            case 221:
               if (scaledMom >= 0.1) {
                 _histMultiEta->fill(scaledEnergy, weight);
-                _histMeanMultiEta->fill(_histMeanMultiEta->binMean(0), weight);
+                _histMeanMultiEta->fill(_histMeanMultiEta->bin(0).xMean(), weight);
                 _weightedTotalNumEta += weight;
               }
               break;
            case 331:
               if (scaledMom >= 0.1) {
                 _histMultiEtaPrime->fill(scaledEnergy, weight);
-                _histMeanMultiEtaPrime->fill(_histMeanMultiEtaPrime->binMean(0), weight);
+                _histMeanMultiEtaPrime->fill(_histMeanMultiEtaPrime->bin(0).xMean(), weight);
                 _weightedTotalNumEtaPrime += weight;
               }
               break;
            case 130: //klong
            case 310: //kshort
               _histMultiK0->fill(scaledMom, weight);
-              _histMeanMultiK0->fill(_histMeanMultiK0->binMean(0), weight);
+              _histMeanMultiK0->fill(_histMeanMultiK0->bin(0).xMean(), weight);
               _weightedTotalNumK0 += weight;
               break;
            case 113:
               _histMultiRho->fill(scaledMom, weight);
-              _histMeanMultiRho->fill(_histMeanMultiRho->binMean(0), weight);
+              _histMeanMultiRho->fill(_histMeanMultiRho->bin(0).xMean(), weight);
               _weightedTotalNumRho += weight;
               break;
            case 223:
               _histMultiOmega782->fill(scaledMom, weight);
-              _histMeanMultiOmega782->fill(_histMeanMultiOmega782->binMean(0), weight);
+              _histMeanMultiOmega782->fill(_histMeanMultiOmega782->bin(0).xMean(), weight);
               _weightedTotalNumOmega782 += weight;
               break;
            case 333:
               _histMultiPhi->fill(scaledMom, weight);
-              _histMeanMultiPhi->fill(_histMeanMultiPhi->binMean(0), weight);
+              _histMeanMultiPhi->fill(_histMeanMultiPhi->bin(0).xMean(), weight);
               _weightedTotalNumPhi += weight;
               break;
            case 313:
            case -313:
               _histMultiKStar892_0->fill(scaledMom, weight);
-              _histMeanMultiKStar892_0->fill(_histMeanMultiKStar892_0->binMean(0), weight);
+              _histMeanMultiKStar892_0->fill(_histMeanMultiKStar892_0->bin(0).xMean(), weight);
               _weightedTotalNumKStar892_0 += weight;
               break;
            case 323:
            case -323:
               _histMultiKStar892Plus->fill(scaledEnergy, weight);
-              _histMeanMultiKStar892Plus->fill(_histMeanMultiKStar892Plus->binMean(0), weight);
+              _histMeanMultiKStar892Plus->fill(_histMeanMultiKStar892Plus->bin(0).xMean(), weight);
               _weightedTotalNumKStar892Plus += weight;
               break;
            case 3122:
            case -3122:
               _histMultiLambda0->fill(scaledMom, weight);
-              _histMeanMultiLambda0->fill(_histMeanMultiLambda0->binMean(0), weight);
+              _histMeanMultiLambda0->fill(_histMeanMultiLambda0->bin(0).xMean(), weight);
               _weightedTotalNumLambda0 += weight;
               break;
            case 3212:
            case -3212:
-              _histMeanMultiSigma0->fill(_histMeanMultiSigma0->binMean(0), weight);
+              _histMeanMultiSigma0->fill(_histMeanMultiSigma0->bin(0).xMean(), weight);
               break;
            case 3312:
            case -3312:
               _histMultiXiMinus->fill(scaledEnergy, weight);
-              _histMeanMultiXiMinus->fill(_histMeanMultiXiMinus->binMean(0), weight);
+              _histMeanMultiXiMinus->fill(_histMeanMultiXiMinus->bin(0).xMean(), weight);
               _weightedTotalNumXiMinus += weight;
               break;
            case 3114:
@@ -343,17 +343,17 @@
            case 3224:
            case -3224:
               _histMultiSigma1385Plus->fill(scaledEnergy, weight);
-              _histMeanMultiSigma1385Plus->fill(_histMeanMultiSigma1385Plus->binMean(0), weight);
+              _histMeanMultiSigma1385Plus->fill(_histMeanMultiSigma1385Plus->bin(0).xMean(), weight);
               _weightedTotalNumSigma1385Plus += weight;
               break;
            case 3324:
            case -3324:
               _histMultiXi1530_0->fill(scaledEnergy, weight);
-              _histMeanMultiXi1530_0->fill(_histMeanMultiXi1530_0->binMean(0), weight);
+              _histMeanMultiXi1530_0->fill(_histMeanMultiXi1530_0->bin(0).xMean(), weight);
               _weightedTotalNumXi1530_0 += weight;
               break;
            case 3334:
-              _histMeanMultiOmegaOmegaBar->fill(_histMeanMultiOmegaOmegaBar->binMean(0), weight);
+              _histMeanMultiOmegaOmegaBar->fill(_histMeanMultiOmegaOmegaBar->bin(0).xMean(), weight);
               break;
         }
       }

Modified: branches/2011-07-aida2yoda/src/Analyses/ATLAS_2010_S8894728.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/ATLAS_2010_S8894728.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/ATLAS_2010_S8894728.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -15,7 +15,7 @@
       for (int b = 0; b < target_dps->size(); ++b) { // loop over bins
         /// @todo Assuming unit weights here! Should use N_effective = sumW**2/sumW2? How?
         const double numentries = moment_profiles[0]->binEntries(b);
-        const double var = moment_profiles[1]->binHeight(b) - intpow(moment_profiles[0]->binHeight(b), 2);
+        const double var = moment_profiles[1]->bin(b).area() - intpow(moment_profiles[0]->bin(b).area(), 2);
         const double sd = isZero(var) ? 0 : sqrt(var); //< Numerical safety check
         target_dps->point(b)->coordinate(1)->setValue(sd);
         if (sd == 0 || numentries < 3) {
@@ -26,11 +26,11 @@
           continue;
         }
         // c2(y) = m4(x) - 4 m3(x) m1(x) - m2(x)^2 + 8 m2(x) m1(x)^2 - 4 m1(x)^4
-        const double var_on_var = moment_profiles[3]->binHeight(b)
-          - 4 * moment_profiles[2]->binHeight(b) * moment_profiles[0]->binHeight(b)
-          - intpow(moment_profiles[1]->binHeight(b), 2)
-          + 8 * moment_profiles[1]->binHeight(b) * intpow(moment_profiles[0]->binHeight(b), 2)
-          - 4 * intpow(moment_profiles[0]->binHeight(b), 4);
+        const double var_on_var = moment_profiles[3]->bin(b).area()
+          - 4 * moment_profiles[2]->bin(b).area() * moment_profiles[0]->bin(b).area()
+          - intpow(moment_profiles[1]->bin(b).area(), 2)
+          + 8 * moment_profiles[1]->bin(b).area() * intpow(moment_profiles[0]->bin(b).area(), 2)
+          - 4 * intpow(moment_profiles[0]->bin(b).area(), 4);
         const double stderr_on_var = sqrt(var_on_var/(numentries-2.0));
         const double stderr_on_sd = stderr_on_var / (2.0*sd);
         target_dps->point(b)->coordinate(1)->setErrorPlus(stderr_on_sd);
@@ -227,15 +227,15 @@
       assert(ptcut.size() == 4);
       for (size_t i = 0; i < nbins; ++i) {
         // First Nch
-        const double binmean_num = hist_num_dphi_500.binMean(i);
-        const double binvalue_num = hist_num_dphi_500.binHeight(i)/hist_num_dphi_500.axis().binWidth(i)/10.0;
+        const double binmean_num = hist_num_dphi_500.bin(i).xMean();
+        const double binvalue_num = hist_num_dphi_500.bin(i).area()/hist_num_dphi_500.axis().binWidth(i)/10.0;
         if (pTlead/GeV >= ptcut[0]) _hist_N_vs_dPhi_1_500->fill(binmean_num, binvalue_num, weight);
         if (pTlead/GeV >= ptcut[1]) _hist_N_vs_dPhi_2_500->fill(binmean_num, binvalue_num, weight);
         if (pTlead/GeV >= ptcut[2]) _hist_N_vs_dPhi_3_500->fill(binmean_num, binvalue_num, weight);
         if (pTlead/GeV >= ptcut[3]) _hist_N_vs_dPhi_5_500->fill(binmean_num, binvalue_num, weight);
         // Then pT
-        const double binmean_pt = hist_pt_dphi_500.binMean(i);
-        const double binvalue_pt = hist_pt_dphi_500.binHeight(i)/hist_pt_dphi_500.axis().binWidth(i)/10.0;
+        const double binmean_pt = hist_pt_dphi_500.bin(i).xMean();
+        const double binvalue_pt = hist_pt_dphi_500.bin(i).area()/hist_pt_dphi_500.axis().binWidth(i)/10.0;
         if (pTlead/GeV >= ptcut[0]) _hist_pT_vs_dPhi_1_500->fill(binmean_pt, binvalue_pt, weight);
         if (pTlead/GeV >= ptcut[1]) _hist_pT_vs_dPhi_2_500->fill(binmean_pt, binvalue_pt, weight);
         if (pTlead/GeV >= ptcut[2]) _hist_pT_vs_dPhi_3_500->fill(binmean_pt, binvalue_pt, weight);

Modified: branches/2011-07-aida2yoda/src/Analyses/ATLAS_2010_S8994773.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/ATLAS_2010_S8994773.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/ATLAS_2010_S8994773.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -92,8 +92,8 @@
       // |Delta(phi)| and so differ by a factor of 2: we have to actually norm for angular range = 2pi
       const size_t nbins = binEdges(13+isqrts,1,1).size() - 1;
       for (size_t i = 0; i < nbins; ++i) {
-        const double binmean_num = hist_num_dphi_500.binMean(i);
-        const double binvalue_num = hist_num_dphi_500.binHeight(i)/hist_num_dphi_500.axis().binWidth(i)/10.0;
+        const double binmean_num = hist_num_dphi_500.bin(i).xMean();
+        const double binvalue_num = hist_num_dphi_500.bin(i).area()/hist_num_dphi_500.axis().binWidth(i)/10.0;
         if (pTlead/GeV >= 1.0) _hist_N_vs_dPhi_1_500->fill(binmean_num, binvalue_num, weight);
         if (pTlead/GeV >= 2.0) _hist_N_vs_dPhi_2_500->fill(binmean_num, binvalue_num, weight);
         if (pTlead/GeV >= 3.0) _hist_N_vs_dPhi_3_500->fill(binmean_num, binvalue_num, weight);

Modified: branches/2011-07-aida2yoda/src/Analyses/ATLAS_2011_S9002537.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/ATLAS_2011_S9002537.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/ATLAS_2011_S9002537.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -79,8 +79,8 @@
       int Nbins = _h_plus->axis().bins();
       std::vector<double> asym, asym_err;
       for (int i=0; i<Nbins; i++) {
-        double num   = _h_plus->binHeight(i) - _h_minus->binHeight(i);
-        double denom = _h_plus->binHeight(i) + _h_minus->binHeight(i);
+        double num   = _h_plus->bin(i).area() - _h_minus->bin(i).area();
+        double denom = _h_plus->bin(i).area() + _h_minus->bin(i).area();
         double err   = _h_plus->binError(i)  + _h_minus->binError(i);
 
         if (num==0 || denom==0) {

Modified: branches/2011-07-aida2yoda/src/Analyses/CDF_1994_S2952106.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/CDF_1994_S2952106.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/CDF_1994_S2952106.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -124,7 +124,7 @@
           0.0274, 0.0230, 0.0201, 0.0120, 0.0100, 0.0080, 0.0051, 0.0051, 0.0010, 0.0010 };
       vector<double> yval_eta3, yerr_eta3;
       for (size_t i = 0;  i < 40; ++i) {
-        const double yval = _tmphistJet3eta->binHeight(i) * (eta3_CDF_sim[i]/eta3_Ideal_sim[i]);
+        const double yval = _tmphistJet3eta->bin(i).area() * (eta3_CDF_sim[i]/eta3_Ideal_sim[i]);
         yval_eta3.push_back(yval/_sumw);
         const double yerr = _tmphistJet3eta->binError(i) * (eta3_CDF_sim_err[i]/eta3_Ideal_sim[i]);
         yerr_eta3.push_back(yerr/_sumw);
@@ -149,7 +149,7 @@
           0.0012, 0.0006, 0.0004, 0.0005, 0.0003 };
       vector<double> yval_R23, yerr_R23;
       for (size_t i = 0;  i < 35; ++i) {
-        const double yval = _tmphistR23->binHeight(i) * (R23_CDF_sim[i]/R23_Ideal_sim[i]);
+        const double yval = _tmphistR23->bin(i).area() * (R23_CDF_sim[i]/R23_Ideal_sim[i]);
         yval_R23.push_back(yval/_sumw);
         const double yerr = _tmphistR23->binError(i) * (R23_CDF_sim_err[i]/R23_Ideal_sim[i]);
         yerr_R23.push_back(yerr/_sumw);
@@ -174,7 +174,7 @@
           0.0232, 0.0243, 0.0238, 0.0248, 0.0235, 0.0298, 0.0292, 0.0291, 0.0268, 0.0316 };
       vector<double> yval_alpha, yerr_alpha;
       for (size_t i = 0;  i < 40; ++i) {
-        const double yval = _tmphistAlpha->binHeight(i) * (alpha_CDF_sim[i]/alpha_Ideal_sim[i]);
+        const double yval = _tmphistAlpha->bin(i).area() * (alpha_CDF_sim[i]/alpha_Ideal_sim[i]);
         yval_alpha.push_back(yval/_sumw);
         const double yerr = _tmphistAlpha->binError(i) * (alpha_CDF_sim_err[i]/alpha_Ideal_sim[i]);
         yerr_alpha.push_back(yerr/_sumw);

Modified: branches/2011-07-aida2yoda/src/Analyses/CDF_2001_S4751469.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/CDF_2001_S4751469.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/CDF_2001_S4751469.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -183,16 +183,16 @@
       // Update the "proper" dphi profile histograms
       for (int i = 0; i < 50; i++) {
         if (ptLead/GeV > 2.0) {
-          _numvsDeltaPhi2->fill(hist_num_dphi_2.binMean(i), hist_num_dphi_2.binHeight(i), weight);
-          _pTvsDeltaPhi2->fill(hist_pt_dphi_2.binMean(i), hist_pt_dphi_2.binHeight(i), weight);
+          _numvsDeltaPhi2->fill(hist_num_dphi_2.bin(i).xMean(), hist_num_dphi_2.bin(i).area(), weight);
+          _pTvsDeltaPhi2->fill(hist_pt_dphi_2.bin(i).xMean(), hist_pt_dphi_2.bin(i).area(), weight);
         }
         if (ptLead/GeV > 5.0) {
-          _numvsDeltaPhi5->fill(hist_num_dphi_5.binMean(i), hist_num_dphi_5.binHeight(i), weight);
-          _pTvsDeltaPhi5->fill(hist_pt_dphi_5.binMean(i), hist_pt_dphi_5.binHeight(i), weight);
+          _numvsDeltaPhi5->fill(hist_num_dphi_5.bin(i).xMean(), hist_num_dphi_5.bin(i).area(), weight);
+          _pTvsDeltaPhi5->fill(hist_pt_dphi_5.bin(i).xMean(), hist_pt_dphi_5.bin(i).area(), weight);
         }
         if (ptLead/GeV > 30.0) {
-          _numvsDeltaPhi30->fill(hist_num_dphi_30.binMean(i), hist_num_dphi_30.binHeight(i), weight);
-          _pTvsDeltaPhi30->fill(hist_pt_dphi_30.binMean(i), hist_pt_dphi_30.binHeight(i), weight);
+          _numvsDeltaPhi30->fill(hist_num_dphi_30.bin(i).xMean(), hist_num_dphi_30.bin(i).area(), weight);
+          _pTvsDeltaPhi30->fill(hist_pt_dphi_30.bin(i).xMean(), hist_pt_dphi_30.bin(i).area(), weight);
         }
       }
 

Modified: branches/2011-07-aida2yoda/src/Analyses/CDF_2005_S6217184.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/CDF_2005_S6217184.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/CDF_2005_S6217184.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -98,7 +98,7 @@
       for (size_t i = 0; i < _ptedges.size()-1; ++i) {
         // Get entry for rad_Psi = 0.2 bin
         Profile1DPtr ph_i = _profhistPsi_pT[i];
-        y.push_back(ph_i->binHeight(2));
+        y.push_back(ph_i->bin(2).area());
         ey.push_back(ph_i->binError(1));
       }
       _profhistPsi_vs_pT->setCoordinate(1, y, ey);

Modified: branches/2011-07-aida2yoda/src/Analyses/CDF_2008_S7541902.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/CDF_2008_S7541902.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/CDF_2008_S7541902.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -129,13 +129,13 @@
       std::vector<double> xerr; xerr.push_back(.5);
       // Fill the first ratio histogram using the special normalisation histogram for the total cross section
       double ratio1to0 = 0.;
-      if (_histJetMultNorm->binHeight(0) > 0.) ratio1to0 = _histJetMult[0]->binHeight(0)/_histJetMultNorm->binHeight(0);
+      if (_histJetMultNorm->bin(0).area() > 0.) ratio1to0 = _histJetMult[0]->bin(0).area()/_histJetMultNorm->bin(0).area();
       // Get the fractional error on the ratio histogram
       double frac_err1to0 = 0.;
-      if (_histJetMult[0]->binHeight(0) > 0.)  frac_err1to0 = _histJetMult[0]->binError(0)/_histJetMult[0]->binHeight(0);
-      if (_histJetMultNorm->binHeight(0) > 0.) {
+      if (_histJetMult[0]->bin(0).area() > 0.)  frac_err1to0 = _histJetMult[0]->binError(0)/_histJetMult[0]->bin(0).area();
+      if (_histJetMultNorm->bin(0).area() > 0.) {
         frac_err1to0 *= frac_err1to0;
-        frac_err1to0 += pow(_histJetMultNorm->binError(0)/_histJetMultNorm->binHeight(0),2.);
+        frac_err1to0 += pow(_histJetMultNorm->binError(0)/_histJetMultNorm->bin(0).area(),2.);
         frac_err1to0 = sqrt(frac_err1to0);
       }
    
@@ -147,12 +147,12 @@
       for (int i = 0; i < 4; ++i) {
         if (i < 3) {
           float ratio = 0.0;
-          if (_histJetMult[i]->binHeight(0) > 0.0) ratio = _histJetMult[i+1]->binHeight(0)/_histJetMult[i]->binHeight(0);
+          if (_histJetMult[i]->bin(0).area() > 0.0) ratio = _histJetMult[i+1]->bin(0).area()/_histJetMult[i]->bin(0).area();
           float frac_err = 0.0;
-          if (_histJetMult[i]->binHeight(0) > 0.0) frac_err = _histJetMult[i]->binError(0)/_histJetMult[i]->binHeight(0);
-          if (_histJetMult[i+1]->binHeight(0) > 0.0) {
+          if (_histJetMult[i]->bin(0).area() > 0.0) frac_err = _histJetMult[i]->binError(0)/_histJetMult[i]->bin(0).area();
+          if (_histJetMult[i+1]->bin(0).area() > 0.0) {
             frac_err *= frac_err;
-            frac_err += pow(_histJetMult[i+1]->binError(0)/_histJetMult[i+1]->binHeight(0),2.);
+            frac_err += pow(_histJetMult[i+1]->binError(0)/_histJetMult[i+1]->bin(0).area(),2.);
             frac_err = sqrt(frac_err);
           }
           yval[i+1].push_back(ratio);

Modified: branches/2011-07-aida2yoda/src/Analyses/CDF_2008_S7782535.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/CDF_2008_S7782535.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/CDF_2008_S7782535.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -101,7 +101,7 @@
       for (size_t i = 0; i < _ptedges.size()-1; ++i) {
         // Get entry for rad_Psi = 0.2 bin
         Profile1DPtr ph_i = _h_Psi_pT[i];
-        y.push_back(1.0 - ph_i->binHeight(1));
+        y.push_back(1.0 - ph_i->bin(1).area());
         ey.push_back(ph_i->binError(1));
       }
       _h_OneMinusPsi_vs_pT->setCoordinate(1, y, ey);

Modified: branches/2011-07-aida2yoda/src/Analyses/D0_2001_S4674421.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/D0_2001_S4674421.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/D0_2001_S4674421.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -140,16 +140,16 @@
           ///       It's only in Axis and VariAxis, but doesn't get passed through to the user. I WANT YODA!!! *SIGH*
           xval.push_back(0.5*(_h_dsigdpt_w->axis().binUpperEdge(ibin)+_h_dsigdpt_w->axis().binLowerEdge(ibin)));
           xerr.push_back(0.5*_h_dsigdpt_w->axis().binWidth(ibin));
-          if (_h_dsigdpt_w->binHeight(ibin) == 0 || _h_dsigdpt_z->binHeight(ibin) == 0) {
+          if (_h_dsigdpt_w->bin(ibin).area() == 0 || _h_dsigdpt_z->bin(ibin).area() == 0) {
             yval.push_back(0.);
             yerr.push_back(0.);
           } else {
-            yval.push_back(scalefactor * _h_dsigdpt_w->binHeight(ibin) / _h_dsigdpt_z->binHeight(ibin));
+            yval.push_back(scalefactor * _h_dsigdpt_w->bin(ibin).area() / _h_dsigdpt_z->bin(ibin).area());
             double dy2 = 0.;
             // binWidth(ibin) is needed because binHeight is actually sumofweights. It's AIDA. Don't ask.  :-((((
-            dy2 += pow(_h_dsigdpt_w->binError(ibin)/_h_dsigdpt_w->binHeight(ibin)*_h_dsigdpt_w->axis().binWidth(ibin),2);
-            dy2 += pow(_h_dsigdpt_z->binError(ibin)/_h_dsigdpt_z->binHeight(ibin)*_h_dsigdpt_z->axis().binWidth(ibin),2);
-            double dy = scalefactor * _h_dsigdpt_w->binHeight(ibin)/_h_dsigdpt_z->binHeight(ibin) * sqrt(dy2);
+            dy2 += pow(_h_dsigdpt_w->binError(ibin)/_h_dsigdpt_w->bin(ibin).area()*_h_dsigdpt_w->axis().binWidth(ibin),2);
+            dy2 += pow(_h_dsigdpt_z->binError(ibin)/_h_dsigdpt_z->bin(ibin).area()*_h_dsigdpt_z->axis().binWidth(ibin),2);
+            double dy = scalefactor * _h_dsigdpt_w->bin(ibin).area()/_h_dsigdpt_z->bin(ibin).area() * sqrt(dy2);
             yerr.push_back(dy);
           }
         }

Modified: branches/2011-07-aida2yoda/src/Analyses/D0_2008_S6879055.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/D0_2008_S6879055.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/D0_2008_S6879055.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -95,7 +95,7 @@
     /// Finalize
     void finalize() {
       // Now divide by the inclusive result
-      _crossSectionRatio->scale(1.0/_crossSectionRatio->binHeight(0));
+      _crossSectionRatio->scale(1.0/_crossSectionRatio->bin(0).area());
 
       // Normalise jet pTs to integrals of data
       // NB. There is no other way to do this, because these quantities are not

Modified: branches/2011-07-aida2yoda/src/Analyses/DELPHI_1996_S3430090.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/DELPHI_1996_S3430090.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/DELPHI_1996_S3430090.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -275,7 +275,7 @@
         }
       }
 
-      _histMultiCharged->fill(_histMultiCharged->binMean(0), numParticles*weight);
+      _histMultiCharged->fill(_histMultiCharged->bin(0).xMean(), numParticles*weight);
 
 
       // Final state of unstable particles to get particle spectra
@@ -285,82 +285,82 @@
         int id = abs(p.pdgId());
         switch (id) {
         case 211:
-          _histMultiPiPlus->fill(_histMultiPiPlus->binMean(0), weight);
+          _histMultiPiPlus->fill(_histMultiPiPlus->bin(0).xMean(), weight);
           break;
         case 111:
-          _histMultiPi0->fill(_histMultiPi0->binMean(0), weight);
+          _histMultiPi0->fill(_histMultiPi0->bin(0).xMean(), weight);
           break;
         case 321:
-          _histMultiKPlus->fill(_histMultiKPlus->binMean(0), weight);
+          _histMultiKPlus->fill(_histMultiKPlus->bin(0).xMean(), weight);
           break;
         case 130:
         case 310:
-          _histMultiK0->fill(_histMultiK0->binMean(0), weight);
+          _histMultiK0->fill(_histMultiK0->bin(0).xMean(), weight);
           break;
         case 221:
-          _histMultiEta->fill(_histMultiEta->binMean(0), weight);
+          _histMultiEta->fill(_histMultiEta->bin(0).xMean(), weight);
           break;
         case 331:
-          _histMultiEtaPrime->fill(_histMultiEtaPrime->binMean(0), weight);
+          _histMultiEtaPrime->fill(_histMultiEtaPrime->bin(0).xMean(), weight);
           break;
         case 411:
-          _histMultiDPlus->fill(_histMultiDPlus->binMean(0), weight);
+          _histMultiDPlus->fill(_histMultiDPlus->bin(0).xMean(), weight);
           break;
         case 421:
-          _histMultiD0->fill(_histMultiD0->binMean(0), weight);
+          _histMultiD0->fill(_histMultiD0->bin(0).xMean(), weight);
           break;
         case 511:
         case 521:
         case 531:
-          _histMultiBPlus0->fill(_histMultiBPlus0->binMean(0), weight);
+          _histMultiBPlus0->fill(_histMultiBPlus0->bin(0).xMean(), weight);
           break;
         case 9010221:
-          _histMultiF0->fill(_histMultiF0->binMean(0), weight);
+          _histMultiF0->fill(_histMultiF0->bin(0).xMean(), weight);
           break;
         case 113:
-          _histMultiRho->fill(_histMultiRho->binMean(0), weight);
+          _histMultiRho->fill(_histMultiRho->bin(0).xMean(), weight);
           break;
         case 323:
-          _histMultiKStar892Plus->fill(_histMultiKStar892Plus->binMean(0), weight);
+          _histMultiKStar892Plus->fill(_histMultiKStar892Plus->bin(0).xMean(), weight);
           break;
         case 313:
-          _histMultiKStar892_0->fill(_histMultiKStar892_0->binMean(0), weight);
+          _histMultiKStar892_0->fill(_histMultiKStar892_0->bin(0).xMean(), weight);
           break;
         case 333:
-          _histMultiPhi->fill(_histMultiPhi->binMean(0), weight);
+          _histMultiPhi->fill(_histMultiPhi->bin(0).xMean(), weight);
           break;
         case 413:
-          _histMultiDStar2010Plus->fill(_histMultiDStar2010Plus->binMean(0), weight);
+          _histMultiDStar2010Plus->fill(_histMultiDStar2010Plus->bin(0).xMean(), weight);
           break;
         case 225:
-          _histMultiF2->fill(_histMultiF2->binMean(0), weight);
+          _histMultiF2->fill(_histMultiF2->bin(0).xMean(), weight);
           break;
         case 315:
-          _histMultiK2Star1430_0->fill(_histMultiK2Star1430_0->binMean(0), weight);
+          _histMultiK2Star1430_0->fill(_histMultiK2Star1430_0->bin(0).xMean(), weight);
           break;
         case 2212:
-          _histMultiP->fill(_histMultiP->binMean(0), weight);
+          _histMultiP->fill(_histMultiP->bin(0).xMean(), weight);
           break;
         case 3122:
-          _histMultiLambda0->fill(_histMultiLambda0->binMean(0), weight);
+          _histMultiLambda0->fill(_histMultiLambda0->bin(0).xMean(), weight);
           break;
         case 3312:
-          _histMultiXiMinus->fill(_histMultiXiMinus->binMean(0), weight);
+          _histMultiXiMinus->fill(_histMultiXiMinus->bin(0).xMean(), weight);
           break;
         case 3334:
-          _histMultiOmegaMinus->fill(_histMultiOmegaMinus->binMean(0), weight);
+          _histMultiOmegaMinus->fill(_histMultiOmegaMinus->bin(0).xMean(), weight);
           break;
         case 2224:
-          _histMultiDeltaPlusPlus->fill(_histMultiDeltaPlusPlus->binMean(0), weight);
+          _histMultiDeltaPlusPlus->fill(_histMultiDeltaPlusPlus->bin(0).xMean(), weight);
           break;
         case 3114:
-          _histMultiSigma1385Plus->fill(_histMultiSigma1385Plus->binMean(0), weight);
+          _histMultiSigma1385Plus->fill(_histMultiSigma1385Plus->bin(0).xMean(), weight);
           break;
         case 3324:
-          _histMultiXi1530_0->fill(_histMultiXi1530_0->binMean(0), weight);
+          _histMultiXi1530_0->fill(_histMultiXi1530_0->bin(0).xMean(), weight);
           break;
         case 5122:
-          _histMultiLambdaB0->fill(_histMultiLambdaB0->binMean(0), weight);
+          _histMultiLambdaB0->fill(_histMultiLambdaB0->bin(0).xMean(), weight);
           break;
         }
       }

Modified: branches/2011-07-aida2yoda/src/Analyses/DELPHI_2002_069_CONF_603.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/DELPHI_2002_069_CONF_603.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/DELPHI_2002_069_CONF_603.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -77,7 +77,7 @@
             }
             if (is_primary) {
               _histXbprim->fill(xp, weight);
-              _histMeanXbprim->fill(_histMeanXbprim->binMean(0), xp, weight);
+              _histMeanXbprim->fill(_histMeanXbprim->bin(0).xMean(), xp, weight);
             }
           }
        
@@ -92,7 +92,7 @@
             }
             if (is_weak) {
               _histXbweak->fill(xp, weight);
-              _histMeanXbweak->fill(_histMeanXbweak->binMean(0), xp, weight);
+              _histMeanXbweak->fill(_histMeanXbweak->bin(0).xMean(), xp, weight);
             }
           }
        

Modified: branches/2011-07-aida2yoda/src/Analyses/Makefile.am
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/Makefile.am	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/Makefile.am	Tue Jul 19 16:58:15 2011	(r3213)
@@ -203,14 +203,14 @@
 # endif
 
 
-# lib_LTLIBRARIES += RivetSPSAnalyses.la
-# RivetSPSAnalyses_la_SOURCES = \
-#     UA1_1990_S2044935.cc \
-#     UA5_1982_S875503.cc \
-#     UA5_1986_S1583476.cc \
-#     UA5_1987_S1640666.cc \
-#     UA5_1988_S1867512.cc \
-#     UA5_1989_S1926373.cc
+lib_LTLIBRARIES += RivetSPSAnalyses.la
+RivetSPSAnalyses_la_SOURCES = \
+    UA1_1990_S2044935.cc \
+    UA5_1982_S875503.cc \
+    UA5_1986_S1583476.cc \
+    UA5_1987_S1640666.cc \
+    UA5_1988_S1867512.cc \
+    UA5_1989_S1926373.cc
 
 
 lib_LTLIBRARIES += RivetMiscAnalyses.la

Modified: branches/2011-07-aida2yoda/src/Analyses/OPAL_1998_S3780481.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/OPAL_1998_S3780481.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/OPAL_1998_S3780481.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -95,7 +95,7 @@
         const double logxp = -std::log(xp);
         _histXpall->fill(xp, weight);
         _histLogXpall->fill(logxp, weight);
-        _histMultiChargedall->fill(_histMultiChargedall->binMean(0), weight);
+        _histMultiChargedall->fill(_histMultiChargedall->bin(0).xMean(), weight);
         switch (flavour) {
           /// @todo Use PDG code enums
         case DQUARK:
@@ -103,17 +103,17 @@
         case SQUARK:
           _histXpuds->fill(xp, weight);
           _histLogXpuds->fill(logxp, weight);
-          _histMultiChargeduds->fill(_histMultiChargeduds->binMean(0), weight);
+          _histMultiChargeduds->fill(_histMultiChargeduds->bin(0).xMean(), weight);
           break;
         case CQUARK:
           _histXpc->fill(xp, weight);
           _histLogXpc->fill(logxp, weight);
-          _histMultiChargedc->fill(_histMultiChargedc->binMean(0), weight);
+          _histMultiChargedc->fill(_histMultiChargedc->bin(0).xMean(), weight);
           break;
         case BQUARK:
           _histXpb->fill(xp, weight);
           _histLogXpb->fill(logxp, weight);
-          _histMultiChargedb->fill(_histMultiChargedb->binMean(0), weight);
+          _histMultiChargedb->fill(_histMultiChargedb->bin(0).xMean(), weight);
           break;
         }
       }

Modified: branches/2011-07-aida2yoda/src/Analyses/UA1_1990_S2044935.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/UA1_1990_S2044935.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/UA1_1990_S2044935.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -137,14 +137,14 @@
       }
       if (fuzzyEquals(sqrtS()/GeV, 900, 1E-3)) {
         // NB. Ref data is normalised to a fixed value not reproducible from MC. Note silly AIDA binHeight forgets the bin width.
-        const double scale08 =  (_hist_Esigd3p08->binHeight(0) > 0) ?
-          0.933e5/(_hist_Esigd3p08->binHeight(0)/_hist_Esigd3p08->axis().binWidth(0)) : 0;
+        const double scale08 =  (_hist_Esigd3p08->bin(0).area() > 0) ?
+          0.933e5/_hist_Esigd3p08->bin(0).height() : 0;
         scale(_hist_Esigd3p08, scale08);
-        const double scale40 = (_hist_Esigd3p40->binHeight(0) > 0) ?
-          1.369e5/(_hist_Esigd3p40->binHeight(0)/_hist_Esigd3p40->axis().binWidth(0)) : 0;
+        const double scale40 = (_hist_Esigd3p40->bin(0).area() > 0) ?
+          1.369e5/_hist_Esigd3p40->bin(0).height() : 0;
         scale(_hist_Esigd3p40, scale40);
-        const double scale80 = (_hist_Esigd3p80->binHeight(0) > 0) ?
-          1.657e5/(_hist_Esigd3p80->binHeight(0)/_hist_Esigd3p80->axis().binWidth(0)) : 0;
+        const double scale80 = (_hist_Esigd3p80->bin(0).area() > 0) ?
+          1.657e5/_hist_Esigd3p80->bin(0).height() : 0;
         scale(_hist_Esigd3p80, scale80);
       }
     }

Modified: branches/2011-07-aida2yoda/src/Analyses/UA5_1982_S875503.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/UA5_1982_S875503.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/UA5_1982_S875503.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -47,7 +47,7 @@
       const ChargedFinalState& cfs = applyProjection<ChargedFinalState>(event, "CFS");
 
       // Fill mean charged multiplicity histos
-      _hist_nch->fill(_hist_nch->binMean(0), cfs.size());
+      _hist_nch->fill(_hist_nch->bin(0).xMean(), cfs.size());
 
       // Iterate over all tracks and fill eta histograms
       foreach (const Particle& p, cfs.particles()) {

Modified: branches/2011-07-aida2yoda/src/Analyses/UA5_1987_S1640666.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/UA5_1987_S1640666.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/UA5_1987_S1640666.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -45,7 +45,7 @@
 
       // Fill histograms
       _hist_nch->fill(Nch, weight);
-      _hist_mean_nch->fill(_hist_mean_nch->binMean(0), Nch);
+      _hist_mean_nch->fill(_hist_mean_nch->bin(0).xMean(), Nch);
 
     }
 

Modified: branches/2011-07-aida2yoda/src/Analyses/UA5_1988_S1867512.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/UA5_1988_S1867512.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/UA5_1988_S1867512.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -137,8 +137,7 @@
       yerrs.push_back(correlation_err(n_40f, n_40b)/sqrt(_sumWPassed));
 
       // Fill the DPS
-      _hist_correl->setCoordinate(0, xvals, xerrs);
-      _hist_correl->setCoordinate(1, yvals, yerrs);
+      _hist_correl.reset( new Scatter2D(xvals, yvals, xerrs, yerrs) );
 
       // Now do the other histo -- clear already defined vectors first
       xvals.clear();
@@ -175,8 +174,7 @@
       // Fill in correlation strength for assymetric intervals,
       // see Tab. 5
       // Fill the DPS
-      _hist_correl_asym->setCoordinate(0, xvals, xerrs);
-      _hist_correl_asym->setCoordinate(1, yvals, yerrs);
+      _hist_correl_asym.reset( new Scatter2D(xvals, yvals, xerrs, yerrs) );
     }
 
     //@}

Modified: branches/2011-07-aida2yoda/src/Analyses/UA5_1989_S1926373.cc
==============================================================================
--- branches/2011-07-aida2yoda/src/Analyses/UA5_1989_S1926373.cc	Tue Jul 19 16:46:34 2011	(r3212)
+++ branches/2011-07-aida2yoda/src/Analyses/UA5_1989_S1926373.cc	Tue Jul 19 16:58:15 2011	(r3213)
@@ -72,7 +72,7 @@
       _hist_nch_eta15->fill(numP15, weight);
       _hist_nch_eta30->fill(numP30, weight);
       _hist_nch_eta50->fill(numP50, weight);
-      _hist_mean_nch->fill(_hist_mean_nch->binMean(0), numP50);
+      _hist_mean_nch->fill(_hist_mean_nch->bin(0).xMean(), numP50);
     }
 
 


More information about the Rivet-svn mailing list