21 #include <Alignment.h>
22 #include <AminoAcidCode.h>
28 namespace Victor {
namespace Align2{
75 virtual unsigned int getNumGap(
unsigned int i);
84 virtual const string getSeq();
99 virtual void setFrequency(
double freq, AminoAcidCode amino,
int i);
102 virtual void setFrequency(
double freq,
char amino,
int i);
105 virtual void setNumGap(
int numGap,
int j);
111 virtual void setSeq(
string master);
179 AminoAcidCode amino = XXX;
182 for (AminoAcidCode j = ALA; j <= TYR; j++) {
200 return static_cast<int> (
gapFreq[i]);
240 setFrequency(freq, aminoAcidOneLetterTranslator(amino), i);
virtual void setAllowGaps(bool g)
Set wether to include/exclude gaps in the master sequence.
Definition: Profile.h:259
Profile()
Default constructor.
Definition: Profile.cc:29
vector< vector< double > > profAliFrequency
Aminoacids frequencies.
Definition: Profile.h:141
virtual void copy(const Profile &orig)
Copy orig object to this object ("deep copy").
Definition: Profile.cc:58
virtual void setSeq(string master)
Set the master sequence.
Definition: Profile.h:254
unsigned int numSeq
Number of sequences.
Definition: Profile.h:145
Calculate a frequency profile or PSSM.
Definition: Profile.h:35
vector< double > gapFreq
Gaps frequencies.
Definition: Profile.h:142
bool gap
If true, consider gaps in the master sequence.
Definition: Profile.h:146
virtual unsigned int getNumSequences()
Return the number of sequences in the profile.
Definition: Profile.h:204
string seq
Master sequence.
Definition: Profile.h:143
virtual Profile * newCopy()
Construct a new "deep copy" of this object.
Definition: Profile.cc:78
Implement a simple alignment type.
Definition: Alignment.h:32
virtual double getAminoFrequencyFromCode(AminoAcidCode amino, unsigned int i)
Return the frequency of the aminoacid amino for position i.
Definition: Profile.h:163
virtual void pCalculateRawFrequency(vector< double > &freq, double &gapFreq, Alignment &ali, unsigned int i)
Calculate the raw (ie. unnormalized) aminoacids frequencies for position i.
Definition: Profile.cc:168
virtual double getFreqMaxAminoFrequency(unsigned int i)
Return the frequency of the most frequent aminoacid for position i.
Definition: Profile.h:173
virtual ~Profile()
Destructor.
Definition: Profile.cc:37
virtual char getAminoMaxFrequency(unsigned int i)
Return the most frequent aminoacid for position i.
Definition: Profile.h:194
virtual const string getSeq()
Return the master sequence.
Definition: Profile.h:214
virtual void reverse()
Reverse profile.
Definition: Profile.cc:135
virtual AminoAcidCode getAminoMaxFrequencyCode(unsigned int i)
Return the most frequent aminoacid for position i.
Definition: Profile.h:178
virtual void setNumSequences(int i)
Set the number of sequences in the profile.
Definition: Profile.h:249
virtual void setNumGap(int numGap, int j)
Set the number of gaps for position i.
Definition: Profile.h:244
Profile & operator=(const Profile &orig)
Assignment operator.
Definition: Profile.cc:44
virtual unsigned int getNumGap(unsigned int i)
Return the number of gaps for position i.
Definition: Profile.h:199
virtual double getAminoFrequency(char amino, unsigned int i)
Return the frequency of the aminoacid amino for position i.
Definition: Profile.h:168
virtual void pConstructData(Alignment &ali)
Construct data from alignment.
Definition: Profile.cc:186
unsigned int seqLen
Lenght of sequences.
Definition: Profile.h:144
virtual string getConsensus()
Return the consensus of the profile.
Definition: Profile.h:219
virtual unsigned int getSequenceLength()
Return the lenght of sequences in the profile.
Definition: Profile.h:209
virtual void setProfile(Alignment &ali)
Set the profile with or without gaps in the master sequence.
Definition: Profile.cc:87
virtual void pResetData()
Reset all data.
Definition: Profile.cc:210
virtual void setFrequency(double freq, AminoAcidCode amino, int i)
Set the frequency of the aminoacid amino for position i.
Definition: Profile.h:234