yat  0.20.3pre
Public Types | Public Member Functions | Related Functions | List of all members
theplu::yat::classifier::DataLookupWeighted1D Class Reference

Class for general weighted vector view. More...

#include <yat/classifier/DataLookupWeighted1D.h>

Public Types

typedef utility::DataWeight value_type
 
typedef const utility::DataWeight const_reference
 
typedef MatrixLookupWeighted::const_row_iterator const_iterator
 'Read Only' iterator
 

Public Member Functions

 DataLookupWeighted1D (const MatrixLookupWeighted &m, const size_t index, const bool row_vector)
 
 DataLookupWeighted1D (const DataLookupWeighted1D &)
 
 DataLookupWeighted1D (const size_t size, double value=0, double weight=1)
 
virtual ~DataLookupWeighted1D ()
 Destructor.
 
const_iterator begin () const
 
double data (const size_t i) const
 
const_iterator end () const
 
size_t size (void) const
 
double weight (const size_t i) const
 
const_reference operator() (const size_t i) const
 access operator
 

Related Functions

(Note that these are not member functions.)

double sum_weight (const DataLookupWeighted1D &)
 
void convert (const DataLookupWeighted1D &, utility::Vector &value, utility::Vector &weight)
 

Detailed Description

Class for general weighted vector view.

See also
MatrixLookupWeighted

Member Typedef Documentation

◆ const_reference

const_reference type is const DataWeight

Since
New in yat 0.5

◆ value_type

value_type is DataWeight

Since
New in yat 0.5

Constructor & Destructor Documentation

◆ DataLookupWeighted1D() [1/3]

theplu::yat::classifier::DataLookupWeighted1D::DataLookupWeighted1D ( const MatrixLookupWeighted m,
const size_t  index,
const bool  row_vector 
)

Constructor.

Parameters
mMatrixLookupWeighted to look into
row_vectorif true (default) DataLookup1D is looking into a row of MatrixLookupWeighted, otherwise looking into a column.
indexwhich row/column to look into.

◆ DataLookupWeighted1D() [2/3]

theplu::yat::classifier::DataLookupWeighted1D::DataLookupWeighted1D ( const DataLookupWeighted1D )

Copy constructor

◆ DataLookupWeighted1D() [3/3]

theplu::yat::classifier::DataLookupWeighted1D::DataLookupWeighted1D ( const size_t  size,
double  value = 0,
double  weight = 1 
)

Construct DataLookup1D that owns its underlying matrix. Object has size size and all its element is equal to value.

Member Function Documentation

◆ begin()

const_iterator theplu::yat::classifier::DataLookupWeighted1D::begin ( ) const
Returns
'Read Only' iterator to beginning of DataLookupWeighted1D.

◆ data()

double theplu::yat::classifier::DataLookupWeighted1D::data ( const size_t  i) const
Returns
data(i)

◆ end()

const_iterator theplu::yat::classifier::DataLookupWeighted1D::end ( ) const
Returns
'Read Only' iterator to end of DataLookupWeighted1D.

◆ size()

size_t theplu::yat::classifier::DataLookupWeighted1D::size ( void  ) const
Returns
number of elements

◆ weight()

double theplu::yat::classifier::DataLookupWeighted1D::weight ( const size_t  i) const
Returns
weight(i)

Friends And Related Function Documentation

◆ convert()

void convert ( const DataLookupWeighted1D ,
utility::Vector value,
utility::Vector weight 
)
related

Converts a DataLookupWeighted1D to two utility::vector

◆ sum_weight()

double sum_weight ( const DataLookupWeighted1D )
related
Returns
sum of weights

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

Generated on Sat Feb 18 2023 03:31:44 for yat by  doxygen 1.8.14