BALL  1.4.79
scoringComponent.h
Go to the documentation of this file.
1 /* scoringComponent.h
2 *
3 * Copyright (C) 2011 Marcel Schumann
4 *
5 * This program free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 3 of the License, or (at
8 * your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, see <http://www.gnu.org/licenses/>.
17 */
18 
19 // ----------------------------------------------------
20 // $Maintainer: Marcel Schumann $
21 // $Authors: Marcel Schumann $
22 // ----------------------------------------------------
23 
24 #ifndef BALL_SCORING_COMMON_SCORINGCOMPONENT_H
25 #define BALL_SCORING_COMMON_SCORINGCOMPONENT_H
26 
27 #include <BALL/DATATYPE/string.h>
30 
31 #include <BALL/KERNEL/atom.h>
32 
33 
34 namespace BALL
35 {
36  class ScoringFunction;
37 
39  {
40  public:
41 
43 
45 
47 
49  void selectBaseFunction(String function);
50 
51  virtual ~ScoringComponent();
52 
53  virtual void clear();
54 
55  virtual bool setup();
56 
59  virtual void setupLigand();
60 
61  ScoringFunction* getScoringFunction() const;
62 
63  void setScoringFunction(ScoringFunction& sf);
64 
65  String getName() const;
66 
67  void setName(const String& name);
68 
69  const String& getTypeName();
70 
71  //virtual double getScore() const;
72 
73  double getRawScore() const;
74 
75  double getScaledScore() const;
76 
79  virtual void update(const vector<std::pair<Atom*, Atom*> >& pair_vector);
80 
83  virtual double updateScore();
84 
85  virtual void setLigandIntraMolecular(bool b);
86 
88  bool isLigandIntraMolecular();
89 
91  bool isGridable();
92 
94  bool isAtomPairwise();
95 
96  void setCoefficient(const double& coeff);
97 
98  const double& getCoefficient();
99 
100  void setNormalizationParameters(double stddev, double mean);
101 
102  void getNormalizationParameters(double& stddev, double& mean);
103 
104  bool isEnabled();
105 
106  void enable();
107 
108  void disable();
109 
110  protected:
115 
119  bool gridable_;
120 
125 
127 
129 
130  double score_;
131 
132  double coefficient_;
133 
134  double stddev_;
135  double mean_;
136 
140  double scaleScore(double score) const;
141 
145  bool enabled_;
146 
154 
155  private:
159  String name_;
160  };
161 }
162 
163 #endif // BALL_SCORING_COMMON_SCORINGCOMPONENT_H
ScoringBaseFunction * base_function_
const char * getName()
Definition: rtti.h:97
-*- Mode: C++; tab-width: 2; -*-
Definition: constants.h:12
#define BALL_EXPORT
Definition: COMMON/global.h:50
ScoringFunction * scoring_function_