X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=ignoregaps.h;h=ccc6b96ee9d6f0e5f3761f9e969741f5e08defdd;hb=2bb9267aa4b4ecdf8488b06605cc9f3f36fa4332;hp=8127b6205e42d18516561565e8a4eb29ccd56ab6;hpb=3117b1c3109121dff476997d3c5db5b47a77729b;p=mothur.git diff --git a/ignoregaps.h b/ignoregaps.h index 8127b62..ccc6b96 100644 --- a/ignoregaps.h +++ b/ignoregaps.h @@ -20,41 +20,42 @@ class ignoreGaps : public Dist { public: + ignoreGaps() {} + ignoreGaps(const ignoreGaps& ddb) {} + void calcDist(Sequence A, Sequence B){ int diff = 0; int length = 0; int start = 0; - int end = 0; + bool overlap = false; - for(int i=0;i=0;i--){ - if(A.getAligned()[i] == '.' || B.getAligned()[i] == '.' || A.getAligned()[i] == '-' || B.getAligned()[i] == '-'){ - } - else{ - end = i; + overlap = true; break; } } - for(int i=start; i<=end; i++){ - if(A.getAligned()[i] == '.' || B.getAligned()[i] == '.'){ + for(int i=start; i