gundam-organization / gundam

GUNDAM, for Generalized and Unified Neutrino Data Analysis Methods, is a suite of applications which aims at performing various statistical analysis with different purposes and setups.
GNU Lesser General Public License v2.1
13 stars 11 forks source link

The prior value added twice in ThrowerMarkHarz toy generator #526

Closed ulyevarou closed 2 months ago

ulyevarou commented 4 months ago

In src/Utils/src/ParameterThrowerMarkHarz.cpp the addition of (*pvals)(i) should be removed

@@ -54,7 +54,8 @@ void ParameterThrowerMarkHarz::ThrowSet(std::vector<double> &parms)
   }
   TVectorD prod = (*chel_dec) * std_rand;
   for (int i = 0; i < npars; i++)
-    parms[i] = prod(i) + (*pvals)(i);
+    parms[i] = prod(i);
 }

since it is added later in the

void ParameterSet::throwParameters(..) ->
par.setThrowValue( par.getPriorValue() + gain_ * throwsList[iPar] );
ClarkMcGrew commented 2 months ago

I've applied my understanding of the fix in #557. @ulyevarou Can you check that I correctly understood your suggested fix and did it correctly? If I did it correctly, feel free to merge and close this, or let me know and I will.

ClarkMcGrew commented 2 months ago

Fixed by #557