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

lti::crispDecisionTree::multivariateCrispDecisionFunction Class Reference

This class implements a multivariate decision. More...

#include <ltiCrispDecisionTree.h>

Inheritance diagram for lti::crispDecisionTree::multivariateCrispDecisionFunction:
Inheritance graph
[legend]
Collaboration diagram for lti::crispDecisionTree::multivariateCrispDecisionFunction:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 multivariateCrispDecisionFunction ()
 multivariateCrispDecisionFunction (const dvector &w, const double &thresh)
 multivariateCrispDecisionFunction (const multivariateCrispDecisionFunction &other)
 ~multivariateCrispDecisionFunction ()
const char * getTypeName () const
multivariateCrispDecisionFunctioncopy (const multivariateCrispDecisionFunction &other)
multivariateCrispDecisionFunctionoperator= (const multivariateCrispDecisionFunction &other)
virtual crispDecisionFunctionclone () const
virtual bool apply (const dvector &data) const
void setCondition (const dvector &w, const double &thresh)
virtual bool write (ioHandler &handler, const bool complete=true) const
virtual bool read (ioHandler &handler, const bool complete=true)

Protected Attributes

dvector weights
double threshold

Detailed Description

This class implements a multivariate decision.

The apply method is true, if the following condition is met.

$\mathbf{x}\cdot\mathbf{a} < c $ with $\mathbf{x}$ the data, $\mathbf{a}$ a weighting vector and $c$ the threshold.

Thus, each node performs an arbitrary linear seperation of the remaining feature space.


Constructor & Destructor Documentation

lti::crispDecisionTree::multivariateCrispDecisionFunction::multivariateCrispDecisionFunction (  ) 

default constructor

lti::crispDecisionTree::multivariateCrispDecisionFunction::multivariateCrispDecisionFunction ( const dvector w,
const double &  thresh 
)

New decision function with the given parameters.

Parameters:
w the weighting vector for the data.
thresh the threshold for the weighted sum
lti::crispDecisionTree::multivariateCrispDecisionFunction::multivariateCrispDecisionFunction ( const multivariateCrispDecisionFunction other  ) 

copy constructor

Parameters:
other the multivariateCrispDecisionFunction object to be copied
lti::crispDecisionTree::multivariateCrispDecisionFunction::~multivariateCrispDecisionFunction (  ) 

destructor


Member Function Documentation

virtual bool lti::crispDecisionTree::multivariateCrispDecisionFunction::apply ( const dvector data  )  const [virtual]

Evaluate the condition implemented in the cdf.

Parameters:
data value to be evaluated
Returns:
true if it meets the condition (left), false if not

Implements lti::crispDecisionTree::crispDecisionFunction.

virtual crispDecisionFunction* lti::crispDecisionTree::multivariateCrispDecisionFunction::clone (  )  const [virtual]
multivariateCrispDecisionFunction& lti::crispDecisionTree::multivariateCrispDecisionFunction::copy ( const multivariateCrispDecisionFunction other  ) 

copy the contents of a multivariateCrispDecisionFunction object

Parameters:
other the multivariateCrispDecisionFunction object to be copied
Returns:
a reference to this multivariateCrispDecisionFunction object

Reimplemented from lti::crispDecisionTree::crispDecisionFunction.

const char* lti::crispDecisionTree::multivariateCrispDecisionFunction::getTypeName (  )  const [virtual]

returns name of this type

Reimplemented from lti::crispDecisionTree::crispDecisionFunction.

multivariateCrispDecisionFunction& lti::crispDecisionTree::multivariateCrispDecisionFunction::operator= ( const multivariateCrispDecisionFunction other  ) 

copy the contents of a multivariateCrispDecisionFunction object

Parameters:
other the multivariateCrispDecisionFunction object to be copied
Returns:
a reference to this multivariateCrispDecisionFunction object

Reimplemented from lti::crispDecisionTree::crispDecisionFunction.

virtual bool lti::crispDecisionTree::multivariateCrispDecisionFunction::read ( ioHandler handler,
const bool  complete = true 
) [virtual]

read the multivariateCrispDecisionFunction from 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::crispDecisionTree::crispDecisionFunction.

void lti::crispDecisionTree::multivariateCrispDecisionFunction::setCondition ( const dvector w,
const double &  thresh 
)

Sets the condition to be tested.

Parameters:
w the weighting vector for the data.
thresh the threshold for the weightes sum
virtual bool lti::crispDecisionTree::multivariateCrispDecisionFunction::write ( ioHandler handler,
const bool  complete = true 
) const [virtual]

write the multivariateCrispDecisionFunction 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::crispDecisionTree::crispDecisionFunction.


Member Data Documentation

Threshold against which the data is tested in the given dimension.

the weighting vector


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

Generated on Sat Apr 10 15:26:48 2010 for LTI-Lib by Doxygen 1.6.1