BAT  0.9.4
The Bayesian analysis toolkit
 All Classes Namespaces Functions Variables Enumerations
BCDataPoint Class Reference

A class representing a data point. More...

#include <BCDataPoint.h>

Public Member Functions

Constructors and destructors
 BCDataPoint (int nvariables)
 
 BCDataPoint (const std::vector< double > &x)
 
Member functions (get)
double GetValue (unsigned index) const
 
const std::vector< double > & GetValues () const
 
unsigned int GetNValues () const
 
Member functions (set)
void SetValue (unsigned index, double value)
 
void SetValues (const std::vector< double > &values)
 

Detailed Description

A class representing a data point.

Author
Daniel Kollar
Kevin Kröninger
Version
1.0
Date
08.2008 This class represents a data point which is the basic unit of information. A data point can be an event, a bin content, etc. Each data point can store several variables of type double. The variables are organized in a vector.

Definition at line 31 of file BCDataPoint.h.

Constructor & Destructor Documentation

BCDataPoint::BCDataPoint ( int  nvariables)

A constructor.

Parameters
nvariablesThe number of variables stored in a data. object

Definition at line 19 of file BCDataPoint.cxx.

BCDataPoint::BCDataPoint ( const std::vector< double > &  x)

A constructor.

Parameters
xThe vector containing the data.

Definition at line 27 of file BCDataPoint.cxx.

Member Function Documentation

unsigned int BCDataPoint::GetNValues ( ) const
inline

Returns the number of values.

Definition at line 65 of file BCDataPoint.h.

double BCDataPoint::GetValue ( unsigned  index) const
Parameters
indexThe index of the variable.
Returns
The value of the variable.

Definition at line 34 of file BCDataPoint.cxx.

const std::vector<double>& BCDataPoint::GetValues ( ) const
inline
Returns
A vector of values.

Definition at line 60 of file BCDataPoint.h.

void BCDataPoint::SetValue ( unsigned  index,
double  value 
)

Set the value of a variable.

Parameters
indexThe index of the variable
valueThe value of the variable

Definition at line 54 of file BCDataPoint.cxx.

void BCDataPoint::SetValues ( const std::vector< double > &  values)

Set the values of all variables.

Parameters
valuesA vector of values

Definition at line 70 of file BCDataPoint.cxx.


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