Commit 5ca7d62c authored by Mikaël Salson's avatar Mikaël Salson Committed by Mathieu Giraud
Browse files

read_score: First quality is space instead of !

This is done to ensure that quality is always > 0 (and the score too).
parent 18a16385
......@@ -80,7 +80,7 @@ size_t ReadQualityScore::qualities[MAX_QUALITY];
float ReadQualityScore::getScore(const Sequence &sequence) const {
memset(qualities, 0, MAX_QUALITY * sizeof(size_t));
for (size_t i = 0; i < sequence.quality.size(); i++) {
int current_quality = (sequence.quality[i]) - '!';
int current_quality = (sequence.quality[i]) - ' ';
if(current_quality >= MAX_QUALITY)
current_quality = MAX_QUALITY - 1;
else if (current_quality < 0)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment