Skip to content

Commit

Permalink
Merge pull request #62 from smithlabcode/update-defn-for-pe-ambig
Browse files Browse the repository at this point in the history
Updating the definition of ambiguous mappers for paired-end
  • Loading branch information
andrewdavidsmith authored Oct 27, 2024
2 parents 9f121df + 25fd5fc commit a83a954
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 8 deletions.
12 changes: 6 additions & 6 deletions data/md5sum.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@ e95a8739a378bc5628c76ffbe8293682 tests/reads_1.fq
447647120a08d3b58162414fae4f4a39 tests/reads.mstats
5487eb32b5492ddba3a95a8461e2ff4c tests/reads_pbat_pe_1.fq
aff19aeae4184c38cf364b3a94527098 tests/reads_pbat_pe_2.fq
d5edb7b66a5db666c98b9954306bbc09 tests/reads_pbat_pe.mstats
6976cb8096a7b36dde542dff893271bc tests/reads_pbat_pe.sam
adcdbadcd3cc14bfb57c170802e16bf7 tests/reads_pbat_pe.mstats
07773c36061cbe787c568d97b9ab0d5e tests/reads_pbat_pe.sam
514bf940e7d5f44e57291a75e1fc6629 tests/reads_pe_1.fq
64e17fc1e424f9cb21879d38ddf745e5 tests/reads_pe_2.fq
e36536c8320a2acbaa66efa0baec145a tests/reads_pe.mstats
4fbbd861d63acee0e01aae8d0d7d071c tests/reads_pe.sam
771991a3d074b6587f6faa8f538f7112 tests/reads_pe.mstats
759c446ff985911feb074fe70843e248 tests/reads_pe.sam
e94e71292fccd255bad3f3694efe7a4b tests/reads_rpbat_pe_1.fq
8bfa00acd0639dc66acd5aa8ac0369d5 tests/reads_rpbat_pe_2.fq
cc99b34bdb1f878d9d49e4140aa8fb19 tests/reads_rpbat_pe.mstats
a0644d10b10bbe96f2fa295f4c02486f tests/reads_rpbat_pe.sam
3a0a49feb314f6cb8fa49c4c114b52fc tests/reads_rpbat_pe.mstats
64566ed0651fabe719f911b86cf05dc6 tests/reads_rpbat_pe.sam
e7a2a3690bc17de0881e7fb2623841ec tests/reads.sam
bcbf01be810cbf4051292813eb6b9225 tests/tRex1.idx
6 changes: 4 additions & 2 deletions src/abismal.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -445,13 +445,15 @@ struct pe_element {
}

bool update(const score_t scr, const se_element &s1, const se_element &s2) {
if (scr > aln_score) {
const auto rd = r1.diffs + r2.diffs;
const auto sd = s1.diffs + s2.diffs;
if (scr > aln_score || (scr == aln_score && sd < rd)) {
r1 = s1;
r2 = s2;
aln_score = scr;
return true;
}
else if (scr == aln_score) {
else if (scr == aln_score && sd == rd) {
r1.set_ambig();
return false;
}
Expand Down

0 comments on commit a83a954

Please sign in to comment.