LTI-Lib latest version v1.9 - last update 10 Apr 2010

lti::varianceFunctor< T >::parameters Class Reference

the parameters for the class varianceFunctor More...

#include <ltiVarianceFunctor.h>

Inheritance diagram for lti::varianceFunctor< T >::parameters:
Inheritance graph
[legend]
Collaboration diagram for lti::varianceFunctor< T >::parameters:
Collaboration graph
[legend]

List of all members.

Public Types

enum  eVarianceType { Empirical = 0, Maxlikely = 1 }

Public Member Functions

 parameters ()
 parameters (const parameters &other)
 ~parameters ()
const char * getTypeName () const
parameterscopy (const parameters &other)
virtual bool write (ioHandler &handler, const bool complete=true) const
virtual bool read (ioHandler &handler, const bool complete=true)
virtual functor::parametersclone () const

Public Attributes

bool rowWise
eVarianceType type
bool correlation

Detailed Description

template<class T>
class lti::varianceFunctor< T >::parameters

the parameters for the class varianceFunctor


Member Enumeration Documentation

Type of the variance.

Enumerator:
Empirical 

Empirical Variance:

\[ \frac{1}{n-1} \sum_i^n (x_i - \mu)^2 \]

.

Maxlikely 

Maximum Likelihood Variance:

\[ \frac{1}{n} \sum_i^n (x_i - \mu)^2 \]

.


Constructor & Destructor Documentation

template<class T >
lti::varianceFunctor< T >::parameters::parameters ( void   )  [inline]
template<class T >
lti::varianceFunctor< T >::parameters::parameters ( const parameters other  )  [inline]

copy constructor

Parameters:
other the parameters object to be copied

Reimplemented from lti::statisticsFunctor::parameters.

References lti::varianceFunctor< T >::parameters::copy().

template<class T >
lti::varianceFunctor< T >::parameters::~parameters (  )  [inline, virtual]

destructor

Reimplemented from lti::statisticsFunctor::parameters.


Member Function Documentation

template<class T >
virtual functor::parameters* lti::varianceFunctor< T >::parameters::clone (  )  const [inline, virtual]

returns a pointer to a clone of the parameters

Reimplemented from lti::statisticsFunctor::parameters.

References lti::varianceFunctor< T >::parameters::parameters().

template<class T >
parameters& lti::varianceFunctor< T >::parameters::copy ( const parameters other  )  [inline]
template<class T >
const char* lti::varianceFunctor< T >::parameters::getTypeName ( void   )  const [inline, virtual]

returns name of this type

Reimplemented from lti::statisticsFunctor::parameters.

template<class T >
virtual bool lti::varianceFunctor< T >::parameters::read ( ioHandler handler,
const bool  complete = true 
) [inline, virtual]

read the parameters from the given ioHandler

Parameters:
handler the ioHandler to be used
complete if true (the default) the enclosing begin/end will be also read, otherwise only the data block will be read.
Returns:
true if write was successful

Reimplemented from lti::functor::parameters.

References lti::varianceFunctor< T >::parameters::Empirical, lti::varianceFunctor< T >::parameters::Maxlikely, lti::ioHandler::readBegin(), lti::ioHandler::readEnd(), lti::varianceFunctor< T >::parameters::rowWise, and lti::varianceFunctor< T >::parameters::type.

template<class T >
virtual bool lti::varianceFunctor< T >::parameters::write ( ioHandler handler,
const bool  complete = true 
) const [inline, virtual]

write the parameters in the given ioHandler

Parameters:
handler the ioHandler to be used
complete if true (the default) the enclosing begin/end will be also written, otherwise only the data block will be written.
Returns:
true if write was successful

Reimplemented from lti::functor::parameters.

References lti::varianceFunctor< T >::parameters::Empirical, lti::varianceFunctor< T >::parameters::rowWise, lti::varianceFunctor< T >::parameters::type, lti::ioHandler::writeBegin(), and lti::ioHandler::writeEnd().


Member Data Documentation

template<class T >
bool lti::varianceFunctor< T >::parameters::correlation

If this flag is true, the covariance matrix is normalized to contain the correlation coefficients instead of the covariances.

Default value: false

template<class T >
bool lti::varianceFunctor< T >::parameters::rowWise

If this flag is true, the variance computation will be row-wise, i.e.

the result will contain a sum of the rows. This is much faster than column-wise, since data do not have to be copied.

Default value: true

Referenced by lti::varianceFunctor< T >::parameters::copy(), lti::varianceFunctor< T >::parameters::parameters(), lti::varianceFunctor< T >::parameters::read(), and lti::varianceFunctor< T >::parameters::write().

The type of the variance computation.

If type == empirical, the empirical variance or covariance matrix is computed (division by number of samples minus 1), otherwise, the maximum likelihood estimator is computed (division by number of samples).

Default value: Empirical

Referenced by lti::varianceFunctor< T >::parameters::copy(), lti::varianceFunctor< T >::parameters::parameters(), lti::varianceFunctor< T >::parameters::read(), and lti::varianceFunctor< T >::parameters::write().


The documentation for this class was generated from the following file:

Generated on Sat Apr 10 15:28:52 2010 for LTI-Lib by Doxygen 1.6.1