1 //uchime by Robert C. Edgar http://drive5.com/uchime This code is donated to the public domain.
\r
15 SA.Seq and SB.Seq align.
\r
16 Reverse strand stuff for nucleotides is handled like this:
\r
17 SA.RevComp must be false.
\r
18 If SB.RevComp is true, then SA.Seq is r.c.'d relative to the sequence in
\r
19 the input file (query or db). If so, coordinates in HSP refer to SB.Seq
\r
20 so are also r.c.'d relative to the original sequence.
\r
37 Log(" %s,%s\n", SA.Label, SB.Label);
\r
41 bool OnDerepHit(const SeqData &SA, const SeqData &SB);
\r
43 bool OnLocalUngappedHit(const SeqData &SA, const SeqData &SB,
\r
44 const HSPData &HSP, float &Evalue, float &FractId);
\r
46 bool OnLocalGappedHit(const SeqData &SA, const SeqData &SB,
\r
47 const HSPData &HSP, const PathData &PD, float &Evalue, float &FractId);
\r
49 bool OnGlobalHit(const SeqData &SA, const SeqData &SB, const PathData &PD,
\r
52 void OnReject(const SeqData &SA, const SeqData &SB, double FractId,
\r
55 void OnNotMatched(const char *Label, unsigned L);
\r
56 void OnNewCluster(unsigned ClusterIndex, const char *Label, unsigned L);
\r
57 void OnNewLibCluster(unsigned ClusterIndex, const char *Label, unsigned L);
\r
58 void OnLibCluster(unsigned ClusterIndex, unsigned Size, double AvgId,
\r
60 void OnNewCluster(unsigned ClusterIndex, unsigned Size, double AvgId,
\r
62 void OnChainCov(const SeqData &NucleoSD, const SeqData &TargetSD,
\r
63 float Score, float ChainCov);
\r
65 void SetUserFieldIndexes(const string &s);
\r
67 void BlastOut(FILE *f, const AlnData &AD);
\r
68 void Blast6Out(FILE *f, const AlnData &AD);
\r
69 void FastaPairOut(FILE *f, const AlnData &AD);
\r
70 void UserOut(FILE *f, const AlnData &AD);
\r
72 void BlastOutORF(FILE *f, const AlnData &AD);
\r
74 void OpenOutputFiles();
\r
75 void CloseOutputFiles();
\r
76 void SetLibSeedCount(unsigned DBSeqCount);
\r
77 const char *UserFieldIndexToStr(unsigned i);
\r
79 extern float **g_SubstMx;
\r
81 static char g_IdChar = '|';
\r
82 static char g_DiffChar = ' ';
\r
84 static inline char GetSymN(byte Letter1, byte Letter2)
\r
86 Letter1 = toupper(Letter1);
\r
87 Letter2 = toupper(Letter2);
\r
88 if (Letter1 == Letter2)
\r
93 static inline char GetSymA(byte Letter1, byte Letter2)
\r
95 Letter1 = toupper(Letter1);
\r
96 Letter2 = toupper(Letter2);
\r
97 if (Letter1 == Letter2)
\r
100 float Score = g_SubstMx[Letter1][Letter2];
\r
108 static inline char GetSym(byte Letter1, byte Letter2, bool Nucleo)
\r
111 return GetSymN(Letter1, Letter2);
\r
113 return GetSymA(Letter1, Letter2);
\r
116 static unsigned GetNDig(unsigned n)
\r
133 extern unsigned *g_UserFieldIndexes;
\r
134 extern unsigned g_UserFieldCount;
\r