Skip to content

Commit

Permalink
fixed bug in amino acid fragment selection, fragment length has to be…
Browse files Browse the repository at this point in the history
… increased by one if sequence starts with an asteriks
  • Loading branch information
AnnSeidel committed Jul 30, 2019
1 parent bc527e6 commit 1667488
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/assembler/hybridassembleresult.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -217,8 +217,9 @@ int dohybridassembleresult(LocalParameters &par) {
tmpNuclAlignments.push_back(nuclBesttHitToExtend);
continue;
}
int hasStart = (aaTargetSeq[0] == '*')? 1:0;
std::string fragment = std::string(nuclTargetSeq, nuclDbStartPos); // +1 get not aligned element
std::string aaFragment = std::string(aaTargetSeq, nuclDbStartPos/3); // +1 get not aligned element
std::string aaFragment = std::string(aaTargetSeq, nuclDbStartPos/3 + hasStart); // +1 get not aligned element

if (fragment.size() + nuclQuery.size() >= par.maxSeqLen) {
Debug(Debug::WARNING) << "Sequence too long in nuclQuery id: " << queryKey << ". "
Expand Down

0 comments on commit 1667488

Please sign in to comment.