Victor
 All Data Structures Functions Variables Friends Pages
LogAverage.h
1 /* This file is part of Victor.
2 
3  Victor is free software: you can redistribute it and/or modify
4  it under the terms of the GNU General Public License as published by
5  the Free Software Foundation, either version 3 of the License, or
6  (at your option) any later version.
7 
8  Victor is distributed in the hope that it will be useful,
9  but WITHOUT ANY WARRANTY; without even the implied warranty of
10  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  GNU General Public License for more details.
12 
13  You should have received a copy of the GNU General Public License
14  along with Victor. If not, see <http://www.gnu.org/licenses/>.
15  */
16 
17 
18 /*************************************************
19  * sub is BLOSUM62 matrix standard log-odds form *
20  *************************************************/
21 
22 #ifndef __LogAverage_H__
23 #define __LogAverage_H__
24 
25 #include <Profile.h>
26 #include <ScoringFunction.h>
27 #include <SubMatrix.h>
28 
29 namespace Victor { namespace Align2{
30 
42  class LogAverage : public ScoringFunction {
43  public:
44 
45  // CONSTRUCTORS:
46 
48  LogAverage(SubMatrix *sub, Profile *pro1, Profile *pro2);
49 
51  LogAverage(const LogAverage &orig);
52 
54  virtual ~LogAverage();
55 
56 
57  // OPERATORS:
58 
60  LogAverage& operator =(const LogAverage &orig);
61 
62 
63  // PREDICATES:
64 
66  virtual double scoringSeq(int i, int j);
67 
68 
69  // MODIFIERS:
70 
72  virtual void copy(const LogAverage &orig);
73 
75  virtual LogAverage* newCopy();
76 
77 
78  protected:
79 
80 
81  private:
82 
83  // ATTRIBUTES:
84 
85  SubMatrix *sub;
86  Profile *pro1;
87  Profile *pro2;
88 
89  };
90 
91 }} // namespace
92 
93 #endif
LogAverage & operator=(const LogAverage &orig)
Assignment operator.
Definition: LogAverage.cc:63
Calculate a frequency profile or PSSM.
Definition: Profile.h:35
Calculate scores for profile to profile alignment using sum of pairs method.
Definition: LogAverage.h:42
virtual ~LogAverage()
Destructor.
Definition: LogAverage.cc:52
Implement a standard substitution matrix.
Definition: SubMatrix.h:30
virtual double scoringSeq(int i, int j)
Calculate scores to create matrix values.
Definition: LogAverage.cc:79
Base class for scoring functions.
Definition: ScoringFunction.h:31
virtual void copy(const LogAverage &orig)
Copy orig object to this object ("deep copy").
Definition: LogAverage.cc:106
virtual LogAverage * newCopy()
Construct a new "deep copy" of this object.
Definition: LogAverage.cc:117
LogAverage(SubMatrix *sub, Profile *pro1, Profile *pro2)
Default constructor.
Definition: LogAverage.cc:44