From 82ba938c2d14c3fa32da74086d73c27aedbf4ebd Mon Sep 17 00:00:00 2001 From: Suter Andreas Date: Mon, 11 Apr 2016 11:11:31 +0200 Subject: [PATCH] make sure that N0 is only estimated if N0 is NOT fixed. --- src/classes/PRunSingleHisto.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/classes/PRunSingleHisto.cpp b/src/classes/PRunSingleHisto.cpp index 2881a32d..020c31e6 100644 --- a/src/classes/PRunSingleHisto.cpp +++ b/src/classes/PRunSingleHisto.cpp @@ -1555,7 +1555,7 @@ void PRunSingleHisto::EstimateN0() if (paramNo > 10000) // i.e. fun or map return; - // still missing: set this value in the parameters + // get the parameters PMsrParamList *param = fMsrInfo->GetMsrParamList(); assert(param); @@ -1564,6 +1564,11 @@ void PRunSingleHisto::EstimateN0() return; } + // check if N0 is fixed. If this is the case, do NOT estimate N0 + if (param->at(paramNo-1).fStep == 0.0) // N0 parameter fixed + return; + + // check that 'backgr.fit' in the msr-file run block is indeed a parameter number. // in case it is a function, nothing will be done. Int_t paramNoBkg = fRunInfo->GetBkgFitParamNo();