BALL::QSAR::ClassificationModel Class Reference

#include <BALL/QSAR/classificationModel.h>

Inheritance diagram for BALL::QSAR::ClassificationModel:
Inheritance graph
[legend]

List of all members.

Public Member Functions

Constructors and Destructors

 ClassificationModel (const QSARData &q)
 ~ClassificationModel ()
virtual void operator= (ClassificationModel &m)

Protected Member Functions

Input and Output. The following methods can be used to implement the functions saveToFile() and readFromFile() in final classes derived from this base-class

void readClassInformationFromFile (std::ifstream &input, int no_classes)
void saveClassInformationToFile (std::ofstream &out)

Friends

class ClassificationValidation

Attributes



ClassificationValidationvalidation
std::vector< int > labels_
std::vector< int > getClassLabels ()

Accessors



std::vector< int > no_substances_
void readLabels ()

Feature discretization function



void(ClassificationModel::* discretizeFeatures )(uint bins, BALL::Matrix< double > &discretization_information)
void(ClassificationModel::* discretizeTestDataFeatures )(Vector< double > &compound, uint bins, const BALL::Matrix< double > &discretization_information)
void equalSpaceDiscretization (uint bins, BALL::Matrix< double > &discretization_information)
void equalSpaceDiscretizationTestData (Vector< double > &compound, uint bins, const BALL::Matrix< double > &discretization_information)

Detailed Description

Definition at line 46 of file classificationModel.h.


Constructor & Destructor Documentation

BALL::QSAR::ClassificationModel::ClassificationModel ( const QSARData q  ) 

constructur,

Parameters:
q QSAR-wrapper object, from which the data for this model should be taken
BALL::QSAR::ClassificationModel::~ClassificationModel (  ) 

Member Function Documentation

void BALL::QSAR::ClassificationModel::equalSpaceDiscretization ( uint  bins,
BALL::Matrix< double > &  discretization_information 
) [protected]

discretizes each feature in such a way that each created bin has an equal range of values

void BALL::QSAR::ClassificationModel::equalSpaceDiscretizationTestData ( Vector< double > &  compound,
uint  bins,
const BALL::Matrix< double > &  discretization_information 
) [protected]
std::vector<int> BALL::QSAR::ClassificationModel::getClassLabels (  ) 
virtual void BALL::QSAR::ClassificationModel::operator= ( ClassificationModel m  )  [virtual]
void BALL::QSAR::ClassificationModel::readClassInformationFromFile ( std::ifstream &  input,
int  no_classes 
) [protected]
void BALL::QSAR::ClassificationModel::readLabels (  )  [protected]

read all different class labels from matrix Y into ClassificationModel.labels

void BALL::QSAR::ClassificationModel::saveClassInformationToFile ( std::ofstream &  out  )  [protected]

Friends And Related Function Documentation

friend class ClassificationValidation [friend]

Reimplemented from BALL::QSAR::Model.

Definition at line 126 of file classificationModel.h.


Member Data Documentation

void(ClassificationModel::* BALL::QSAR::ClassificationModel::discretizeFeatures)(uint bins, BALL::Matrix< double > &discretization_information) [protected]

Interface function-definition for discretization of features.
Thus, various functions that do the actual discretization can be created as members of ClassificationModel, allowing switching of the discretization technique by only (re-)setting this function-pointer.

Parameters:
bins the number of discrete values to be created for each features
discretization_information a BALL::Matrix<double> into which the information about the applied discretization should be saved (into one column per feature).
This BALL::Matrix<double> can later be used to discretize test data according to the discretization of the training data.

Definition at line 101 of file classificationModel.h.

void(ClassificationModel::* BALL::QSAR::ClassificationModel::discretizeTestDataFeatures)(Vector< double > &compound, uint bins, const BALL::Matrix< double > &discretization_information) [protected]

Discretizes test data according to the given discretization of the training data.

Parameters:
discretization_information the discretization according to which the current descriptor_matrix should be discretized.

Definition at line 105 of file classificationModel.h.

std::vector<int> BALL::QSAR::ClassificationModel::labels_ [protected]

labels for the different classes

Definition at line 123 of file classificationModel.h.

the number of substances in each class of the training data

Definition at line 81 of file classificationModel.h.

a ClassificationValidation object, that is used to validate this model and that will contain the results of the validations

Definition at line 66 of file classificationModel.h.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Defines
Generated by  doxygen 1.6.3