BALL  1.4.79
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
oplsModel.h
Go to the documentation of this file.
1 /* oplsModel.h
2  *
3  * Copyright (C) 2009 Marcel Schumann
4  *
5  * This file is part of QuEasy -- A Toolbox for Automated QSAR Model
6  * Construction and Validation.
7  * QuEasy is free software; you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation; either version 3 of the License, or (at
10  * your option) any later version.
11  *
12  * QuEasy is distributed in the hope that it will be useful, but
13  * WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15  * General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program; if not, see <http://www.gnu.org/licenses/>.
19  */
20 
21  // -*- Mode: C++; tab-width: 2; -*-
22 // vi: set ts=2:
23 //
24 //
25 
26 #ifndef OPLSMODEL
27 #define OPLSMODEL
28 
29 #ifndef PLSMODEL
30 #include <BALL/QSAR/plsModel.h>
31 #endif
32 
33 
34 
35 namespace BALL
36 {
37  namespace QSAR
38  {
40  {
41  public:
45  OPLSModel(const QSARData& q);
46 
47  ~OPLSModel();
48  EIGEN_MAKE_ALIGNED_OPERATOR_NEW
50 
51 
54 
55 
57  void train();
58 
59  const Eigen::MatrixXd* getWOrtho();
60 
61  const Eigen::MatrixXd* getTOrtho();
62 
63  int getNoOrthoComponents();
64 
65  void setNoOrthoComponents(int d);
66 
67  bool optimizeParameters(int k, int no_steps);
68  //RowVector predict(const vector<double>& substance, bool transform);
69 
70  void setParameters(vector<double>& v);
71 
72  vector<double> getParameters() const;
74 
75 
76  private:
80  Eigen::MatrixXd T_ortho_;
81  Eigen::MatrixXd W_ortho_;
82 
83  int no_ortho_components_;
85  };
86  }
87 }
88 
89 
90 #endif // OPLSMODEL
BALL_EXTERN_VARIABLE const double k
Definition: constants.h:93
#define BALL_EXPORT
Definition: COMMON/global.h:50