improvement on: allow to draw theory only at the data points for PRunNonMusr.
This commit is contained in:
parent
cb53b1b67b
commit
3a75ced375
@ -441,11 +441,21 @@ Bool_t PRunNonMusr::PrepareViewData()
|
||||
|
||||
// typically take 1000 points to calculate the theory, except if there are more data points, than take that number
|
||||
Double_t xStep;
|
||||
if ((fData.GetX()->size() > 1000.0) || fTheoAsData)
|
||||
if (fData.GetX()->size() > 1000.0)
|
||||
xStep = (xMax-xMin)/fData.GetX()->size();
|
||||
else
|
||||
xStep = (xMax-xMin)/1000.0;
|
||||
|
||||
if (fTheoAsData) {
|
||||
Double_t xx;
|
||||
for (UInt_t i=0; i<fRawRunData->fDataNonMusr.GetData()->at(xIndex).size(); i++) {
|
||||
// fill x-vector
|
||||
xx = fRawRunData->fDataNonMusr.GetData()->at(xIndex).at(i);
|
||||
fData.AppendXTheoryValue(xx);
|
||||
// fill y-vector
|
||||
fData.AppendTheoryValue(fTheory->Func(xx, par, fFuncValues));
|
||||
}
|
||||
} else {
|
||||
Double_t xx = xMin;
|
||||
do {
|
||||
// fill x-vector
|
||||
@ -455,6 +465,7 @@ Bool_t PRunNonMusr::PrepareViewData()
|
||||
// calculate next xx
|
||||
xx += xStep;
|
||||
} while (xx < xMax);
|
||||
}
|
||||
|
||||
// clean up
|
||||
par.clear();
|
||||
|
Loading…
x
Reference in New Issue
Block a user