BioInt
1.02.00
BioInt: An integrative biological object-oriented application framework and interpreter
|
00001 #ifndef BIOPROTEINMULTIPATTERNALIGNMENT_H 00002 #define BIOPROTEINMULTIPATTERNALIGNMENT_H 00003 00004 #include <iostream> 00005 #include <fstream> 00006 #include <string> 00007 #include <sstream> 00008 #include <vector> 00009 00010 #include "BioUtilities.h" 00011 #include "BioProteinSequence.h" 00012 #include "BioSwissProt.h" 00013 #include "BioFasta.h" 00014 #include "BioProteinSequenceRepeatAlignment.h" 00015 #include "BioPostScript.h" 00016 00017 using namespace std; 00018 00019 class BioProteinMultiPatternAlignment 00020 { 00021 friend bool operator >(const BioProteinMultiPatternAlignment& , const BioProteinMultiPatternAlignment&); 00022 friend bool operator <(const BioProteinMultiPatternAlignment& , const BioProteinMultiPatternAlignment&); 00023 friend bool operator ==(const BioProteinMultiPatternAlignment& , const BioProteinMultiPatternAlignment&); 00024 00025 vector <BioProteinSequenceRepeatAlignment> reapAligns; 00026 00027 string fileName,substitutionMatrix; 00028 00029 int match,misMatch; 00030 00031 string querySequence; 00032 00033 string outSeq1_,outSeq2_; 00034 00035 vector <int> offsetStart; 00036 vector <int> offsetEnd; 00037 00038 vector < vector <int> > finalstposs; 00039 vector < vector <int> > finaledposs; 00040 00041 BioMatrix tMatrix; 00042 00043 vector <int> scores; 00044 00045 int status; 00046 00047 void tempMatrix(string,string); 00048 00049 vector<string> processInputPattern(string); 00050 00051 vector<int> processStringForPatterns(string ); 00052 00053 bool checkInt(string); 00054 00055 void showAlign(ostream & = cout); 00056 00057 void makeAlign(); 00058 00059 void init(); 00060 00061 public: 00062 BioProteinMultiPatternAlignment(); 00063 ~BioProteinMultiPatternAlignment(); 00064 BioProteinMultiPatternAlignment(BioProteinSequence,string,string="BLOSUM62",int ReapIden=100,int GP=-50,int extn=-9999,int TH=20); 00065 BioProteinMultiPatternAlignment(BioProteinSequence,string,string,string,int ReapIden=100,int GP=-50,int extn=-9999,int TH=20); 00066 BioProteinMultiPatternAlignment(BioProteinSequence,string,int ReapIden,int MS,int MMS,int GP=-50,int extn=-9999,int TH=20); 00067 00068 00069 BioProteinMultiPatternAlignment(BioFasta,string,string="BLOSUM62",int ReapIden=100,int GP=-50,int extn=-9999,int TH=20); 00070 BioProteinMultiPatternAlignment(BioFasta,string,string,string,int ReapIden=100,int GP=-50,int extn=-9999,int TH=20); 00071 BioProteinMultiPatternAlignment(BioFasta,string,int ReapIden,int MS,int MMS,int GP=-50,int extn=-9999,int TH=20); 00072 00073 BioProteinMultiPatternAlignment(string,string,string="BLOSUM62",int ReapIden=100,int GP=-50,int extn=-9999,int TH=20); 00074 BioProteinMultiPatternAlignment(string,string,string,string,int ReapIden=100,int GP=-50,int extn=-9999,int TH=20); 00075 BioProteinMultiPatternAlignment(string,string,int ReapIden,int MS,int MMS,int GP=-50,int extn=-9999,int TH=20); 00076 00077 void setSequence(BioProteinSequence); 00078 void setSequence(BioFasta); 00079 void setSequence(string); 00080 00081 void addPattern(string,int ReapIden=100,int GP=-50,int extn=-9999,int TH=20); 00082 00083 void setSubstitutionMatrix(string); 00084 void setSubstitutionMatrix(string,string); 00085 void setMatchMisMatchScore(int MS=1,int MMS=0); 00086 00087 void setGapPenalty(int GP=-11,int extn=-9999, int index = -1); 00088 void setRepeatIdentity(int identity,int index=-1); 00089 void setThreshold(int,int index = -1); 00090 void setOffsetRange(int st, int ed,int index=-1); 00091 void setOrder(string); 00092 void setGaps(int cou,int index=-1); 00093 00094 void showAlignment(ostream & = cout); 00095 void showAlignment(BioPostScript& ps,float=100,float=650,float=450); 00096 00097 int getRepeatStartingPosition(int); 00098 00099 int getRepeatEndingPosition(int); 00100 00101 int getNumberOfRepeats(); 00102 00103 int getScore(int); 00104 string getRepeat(int); 00105 string getAlignedRepeat(int); 00106 00107 }; 00108 00109 #endif