37 #ifndef _vpStatisticalTestMeanAdjustedCUSUM_h_
38 #define _vpStatisticalTestMeanAdjustedCUSUM_h_
40 #include <visp3/core/vpConfig.h>
42 #include <visp3/core/vpStatisticalTestAbstract.h>
95 virtual void computeDeltaAndLimits();
104 #if (VISP_CXX_STANDARD >= VISP_CXX_STANDARD_11)
115 #if (VISP_CXX_STANDARD >= VISP_CXX_STANDARD_11)
127 #if (VISP_CXX_STANDARD >= VISP_CXX_STANDARD_11)
138 #if (VISP_CXX_STANDARD >= VISP_CXX_STANDARD_11)
216 void init(
const float &h,
const float &k,
const unsigned int &nbPtsForStats);
227 void init(
const float &delta,
const float &limitDown,
const float &limitUp,
const unsigned int &nbPtsForStats);
239 void init(
const float &h,
const float &k,
const float &mean,
const float &stdev);
250 void init(
const float &delta,
const float &limitDown,
const float &limitUp,
const float &mean,
const float &stdev);
260 m_half_delta = 0.5f * delta;
269 inline void setLimits(
const float &limitDown,
const float &limitUp)
271 m_limitDown = limitDown;
Base class for methods detecting the drift of the mean of a process.
vpMeanDriftType
Enum that indicates if a drift of the mean occurred.
virtual vpMeanDriftType detectUpwardMeanDrift()=0
Detects if a upward mean drift occurred.
void init()
(Re)Initialize the algorithm.
virtual bool updateStatistics(const float &signal)
Update m_s and if enough values are available, compute the mean, the standard deviation and the limit...
virtual void updateTestSignals(const float &signal)=0
Update the test signals.
virtual vpMeanDriftType detectDownwardMeanDrift()=0
Detects if a downward mean drift occurred.
Class that permits to perform a mean adjusted Cumulative Sum test.
float getTestSignalMinus() const
Get the latest value of the test signal for downward jumps of the mean.
float getTestSignalPlus() const
Get the latest value of the test signal for upward jumps of the mean.
float getH() const
Get the alarm factor.
void setDelta(const float &delta)
Set the slack of the CUSUM test, i.e. the minimum value of the jumps we want to detect.
void setLimits(const float &limitDown, const float &limitUp)
Set the upward and downward jump limits.
float getDelta() const
Get the slack of the CUSUM test, i.e. amplitude of mean shift we want to be able to detect.
float getK() const
Get the detection factor.