fastdist.cpp
来自「unix,linux下编译。用于蛋白质」· C++ 代码 · 共 57 行
CPP
57 行
#include "muscle.h"
#include "distfunc.h"
#include "seqvect.h"
void DistPWScoreDist(const SeqVect &v, DistFunc &DF);
void DistUnaligned(const SeqVect &v, DISTANCE DistMethod, DistFunc &DF)
{
const unsigned uSeqCount = v.Length();
switch (DistMethod)
{
case DISTANCE_Kmer6_6:
DistKmer6_6(v, DF);
break;
case DISTANCE_Kmer20_3:
DistKmer20_3(v, DF);
break;
case DISTANCE_Kmer20_4:
FastDistKmer(v, DF);
break;
case DISTANCE_Kbit20_3:
DistKbit20_3(v, DF);
break;
case DISTANCE_Kmer4_6:
DistKmer4_6(v, DF);
break;
case DISTANCE_PWKimura:
DistPWKimura(v, DF);
break;
case DISTANCE_PWScoreDist:
DistPWScoreDist(v, DF);
break;
default:
Quit("DistUnaligned, unsupported distance method %d", DistMethod);
}
// const char **SeqNames = (const char **) malloc(uSeqCount*sizeof(char *));
for (unsigned uSeqIndex = 0; uSeqIndex < uSeqCount; ++uSeqIndex)
{
const Seq &s = *(v[uSeqIndex]);
const char *ptrName = s.GetName();
unsigned uId = s.GetId();
DF.SetName(uSeqIndex, ptrName);
DF.SetId(uSeqIndex, uId);
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?