mirror of
https://github.com/aportelli/LatAnalyze.git
synced 2025-04-11 03:20:46 +01:00
Merge remote-tracking branch 'fork/develop' into develop
This commit is contained in:
commit
6990d16ca0
@ -234,6 +234,12 @@ DVec XYSampleData::getYError(const Index j)
|
|||||||
return data_.getYError(j);
|
return data_.getYError(j);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void XYSampleData::setChi2PerDofBound(double upper_lim, double lower_lim)
|
||||||
|
{
|
||||||
|
chi2PerDofu_ = upper_lim;
|
||||||
|
chi2PerDofl_ = lower_lim;
|
||||||
|
}
|
||||||
|
|
||||||
bool XYSampleData::checkFit()
|
bool XYSampleData::checkFit()
|
||||||
{
|
{
|
||||||
return goodFit_;
|
return goodFit_;
|
||||||
@ -241,7 +247,7 @@ bool XYSampleData::checkFit()
|
|||||||
|
|
||||||
void XYSampleData::checkChi2PerDof(double Chi2PerDof)
|
void XYSampleData::checkChi2PerDof(double Chi2PerDof)
|
||||||
{
|
{
|
||||||
if(Chi2PerDof >= 2 or Chi2PerDof < 0 or isnan(Chi2PerDof))
|
if(Chi2PerDof >= chi2PerDofu_ or Chi2PerDof < chi2PerDofl_ or isnan(Chi2PerDof))
|
||||||
{
|
{
|
||||||
goodFit_ = false;
|
goodFit_ = false;
|
||||||
}
|
}
|
||||||
|
@ -91,6 +91,8 @@ public:
|
|||||||
const DMat & getXYVar(const Index i, const Index j);
|
const DMat & getXYVar(const Index i, const Index j);
|
||||||
DVec getXError(const Index i);
|
DVec getXError(const Index i);
|
||||||
DVec getYError(const Index j);
|
DVec getYError(const Index j);
|
||||||
|
// fit criteria
|
||||||
|
void setChi2PerDofBound(double upper_lim, double lower_lim);
|
||||||
bool checkFit(); // check fit candidate based on chi2PerDof
|
bool checkFit(); // check fit candidate based on chi2PerDof
|
||||||
void checkChi2PerDof(double Chi2PerDof);
|
void checkChi2PerDof(double Chi2PerDof);
|
||||||
// get total fit variance matrix and its pseudo-inverse
|
// get total fit variance matrix and its pseudo-inverse
|
||||||
@ -136,6 +138,7 @@ private:
|
|||||||
bool initData_{true}, computeVarMat_{true};
|
bool initData_{true}, computeVarMat_{true};
|
||||||
bool initXMap_{true};
|
bool initXMap_{true};
|
||||||
bool goodFit_{true}; // used to break minimisation if central sample chi2PerDof is bad
|
bool goodFit_{true}; // used to break minimisation if central sample chi2PerDof is bad
|
||||||
|
double chi2PerDofu_{1e10}, chi2PerDofl_{0};
|
||||||
};
|
};
|
||||||
|
|
||||||
/******************************************************************************
|
/******************************************************************************
|
||||||
|
Loading…
x
Reference in New Issue
Block a user