Victor
 All Data Structures Functions Variables Friends Pages
HenikoffProfile.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 #ifndef __HenikoffProfile_H__
18 #define __HenikoffProfile_H__
19 
20 #include <Profile.h>
21 
22 namespace Victor { namespace Align2{
23 
35  class HenikoffProfile : public Profile {
36  public:
37 
38  // CONSTRUCTORS:
39 
42 
44  HenikoffProfile(const HenikoffProfile &orig);
45 
47  virtual ~HenikoffProfile();
48 
49 
50  // OPERATORS:
51 
54 
55 
56  // MODIFIERS:
57 
59  virtual void copy(const HenikoffProfile &orig);
60 
62  virtual HenikoffProfile* newCopy();
63 
64 
65  // HELPERS:
66 
68  //to save computational time we suggest cLen=25. Francesco Lovo 2012
69  virtual void pCalculateWeight(Alignment &ali, unsigned int cLen = 50);
70 
72  virtual void pCalculateRawFrequency(vector<double> &freq, double &gapFreq,
73  Alignment &ali, unsigned int i);
74 
76  virtual void pConstructData(Alignment &ali);
77 
78 
79  protected:
80 
81 
82  private:
83 
84  vector< vector<double> > aliWeight;
85 
86  };
87 
88 }} // namespace
89 
90 #endif
virtual void pCalculateWeight(Alignment &ali, unsigned int cLen=50)
Calculate alignment weights.
Definition: HenikoffProfile.cc:97
virtual void pConstructData(Alignment &ali)
Construct data from alignment.
Definition: HenikoffProfile.cc:338
HenikoffProfile()
Default constructor.
Definition: HenikoffProfile.cc:36
Calculate a frequency profile or PSSM.
Definition: Profile.h:35
virtual void copy(const HenikoffProfile &orig)
Copy orig object to this object ("deep copy").
Definition: HenikoffProfile.cc:68
vector< double > gapFreq
Gaps frequencies.
Definition: Profile.h:142
Implement a simple alignment type.
Definition: Alignment.h:32
virtual void pCalculateRawFrequency(vector< double > &freq, double &gapFreq, Alignment &ali, unsigned int i)
Calculate the raw (ie. unnormalized) aminoacids frequencies for position i.
Definition: HenikoffProfile.cc:320
Calculate a frequency profile or PSSM using Henikoff weighting scheme.
Definition: HenikoffProfile.h:35
virtual HenikoffProfile * newCopy()
Construct a new "deep copy" of this object.
Definition: HenikoffProfile.cc:84
virtual ~HenikoffProfile()
Destructor.
Definition: HenikoffProfile.cc:43
HenikoffProfile & operator=(const HenikoffProfile &orig)
Assignment operator.
Definition: HenikoffProfile.cc:54