]> git.donarmstrong.com Git - mothur.git/blobdiff - qualityscores.cpp
sffinfo bug with flow grams right index when clipQualRight=0
[mothur.git] / qualityscores.cpp
index 4998b3d1c4dabd18b97fb8f33e36860127e757e5..33ca1728052e4db59372fc2d8129e5bcbaf729c5 100644 (file)
@@ -34,13 +34,17 @@ QualityScores::QualityScores(ifstream& qFile){
                int score;
                seqName = getSequenceName(qFile);
                
+        if (m->debug) { m->mothurOut("[DEBUG]: name = '" + seqName + "'\n.");  }
+        
                if (!m->control_pressed) {
             string qScoreString = m->getline(qFile);
-            //cout << qScoreString << endl;
+            
+            if (m->debug) { m->mothurOut("[DEBUG]: scores = '" + qScoreString + "'\n.");  }
+            
             while(qFile.peek() != '>' && qFile.peek() != EOF){
                 if (m->control_pressed) { break; }
                 string temp = m->getline(qFile);
-                //cout << temp << endl;
+                if (m->debug) { m->mothurOut("[DEBUG]: scores = '" + temp + "'\n.");  }
                 qScoreString +=  ' ' + temp;
             }
             //cout << "done reading " << endl; 
@@ -51,6 +55,8 @@ QualityScores::QualityScores(ifstream& qFile){
                 string temp;
                 qScoreStringStream >> temp;  m->gobble(qScoreStringStream);
                 
+                if (m->debug) { m->mothurOut("[DEBUG]: score " + toString(qScores.size()) + " = '" + temp + "'\n.");  }
+                
                 //check temp to make sure its a number
                 if (!m->isContainingOnlyDigits(temp)) { m->mothurOut("[ERROR]: In sequence " + seqName + "'s quality scores, expected a number and got " + temp + ", setting score to 0."); m->mothurOutEndLine(); temp = "0"; }
                 convert(temp, score);