32#if defined(MultiStatistics_RECURSES)
33#error Recursive header files inclusion detected in MultiStatistics.h
36#define MultiStatistics_RECURSES
38#if !defined MultiStatistics_h
40#define MultiStatistics_h
45#include "DGtal/base/Common.h"
102 const std::vector<unsigned int> & indices );
112 inline unsigned int nb()
const;
120 inline unsigned int samples(
const unsigned int k )
const;
129 inline double mean(
const unsigned int k )
const;
138 inline double variance(
const unsigned int k )
const;
156 inline double max(
const unsigned int k )
const;
177 inline double min(
const unsigned int k )
const;
188 inline unsigned int minIndice(
const unsigned int k )
const;
204 inline double value(
const unsigned int k,
const unsigned int i )
const;
232 template <
class Iter>
256 void init(
unsigned int size,
bool storeSamples );
286 double covariance(
const unsigned int x,
const unsigned int y,
287 const unsigned int s = 0,
unsigned int e = 0 )
const;
300 const unsigned int y )
const;
456#if !defined(BUILD_INLINE)
457#include "DGtal/math/MultiStatistics.ih"
466#undef MultiStatistics_RECURSES
Aim: This class stores a set of sample values for several variables and can then compute different st...
double variance(const unsigned int k) const
static void read(std::istream &in, MultiStatistics &samples, const std::vector< unsigned int > &indices)
double max(const unsigned int k) const
MultiStatistics(const unsigned int size, const bool storeSamples=false)
double mean(const unsigned int k) const
void addValue(unsigned int k, double v)
void addValues(const unsigned int k, Iter b, Iter e)
void init(unsigned int size, bool storeSamples)
double median(const unsigned int k)
void selfDisplay(std::ostream &out) const
unsigned int maxIndice(unsigned int k) const
double min(const unsigned int k) const
MultiStatistics & operator=(const MultiStatistics &other)
double covariance(const unsigned int x, const unsigned int y, const unsigned int s=0, unsigned int e=0) const
std::pair< double, double > linearRegression(const unsigned int x, const unsigned int y) const
unsigned int minIndice(const unsigned int k) const
unsigned int samples(const unsigned int k) const
unsigned int * myIndiceMax
unsigned int * myIndiceMin
std::vector< double > * myValues
MultiStatistics(const MultiStatistics &other)
double value(const unsigned int k, const unsigned int i) const
double unbiasedVariance(const unsigned int k) const
DGtal is the top-level namespace which contains all DGtal functions and types.
std::ostream & operator<<(std::ostream &out, const ClosedIntegerHalfPlane< TSpace > &object)