]> git.donarmstrong.com Git - mothur.git/commitdiff
a few changes to chimera classes
authorwestcott <westcott>
Wed, 25 Nov 2009 16:50:42 +0000 (16:50 +0000)
committerwestcott <westcott>
Wed, 25 Nov 2009 16:50:42 +0000 (16:50 +0000)
ccode.cpp
chimeracheckrdp.cpp
chimeraslayer.cpp

index a43a5a10e9e1aa72eb0e26f858de55e5b507afc0..0a9214ef39e16b99b31694fb2bff53e9e25fdc80 100644 (file)
--- a/ccode.cpp
+++ b/ccode.cpp
@@ -423,15 +423,15 @@ vector<int> Ccode::findWindows(int query) {
                it = trim[query].begin();
                
                int length = it->second - it->first;
-               
+       
                //default is wanted = 10% of total length
                if (windowSizes[query] > length) { 
                        mothurOut("You have slected a window larger than your sequence length after all filters, masks and trims have been done. I will use the default 10% of sequence length.");
                        windowSizes[query] = length / 10;
                }else if (windowSizes[query] == 0) { windowSizes[query] = length / 10;  }
-               else if (windowSizes[query] > (length 20)) {
+               else if (windowSizes[query] > (length * 0.20)) {
                        mothurOut("You have selected a window that is larger than 20% of your sequence length.  This is not recommended, but I will continue anyway."); mothurOutEndLine();
-               }else if (windowSizes[query] < (length 5)) {
+               }else if (windowSizes[query] < (length * 0.05)) {
                        mothurOut("You have selected a window that is smaller than 5% of your sequence length.  This is not recommended, but I will continue anyway."); mothurOutEndLine();
                }
                
index f9b2319a0dfc489c41d1634c2e4519e3db73bdc2..dcd2ef34ddadc26dc2574b8d6d903454e417aa36 100644 (file)
@@ -43,7 +43,7 @@ void ChimeraCheckRDP::print(ostream& out) {
                                        out << IS[i][k].score << '\t'; 
                                        //if (IS[i][k].score > chimeraCutoff) {  isChimeric[i] = true;   lastChimericWindowFound = k;           }                       
                                }
-                               
+                               out << endl;
                                //if (isChimeric[i]) { 
                                        //mothurOut(querySeqs[i]->getName() + "\tIS: " + toString(IS[i][lastChimericWindowFound].score) + "\tbreakpoint: " + toString(IS[i][lastChimericWindowFound].midpoint) + "\tleft parent: " + IS[i][lastChimericWindowFound].leftParent + "\tright parent: " + IS[i][lastChimericWindowFound].rightParent); mothurOutEndLine();
                                        //out << endl << "chimera: YES" << endl;
@@ -65,6 +65,7 @@ void ChimeraCheckRDP::print(ostream& out) {
                                }
                }
                
+               mothurOut("This method does not determine if a sequence is chimeric, but allows you to make that determination based on the IS values."); mothurOutEndLine();
        }
        catch(exception& e) {
                errorOut(e, "ChimeraCheckRDP", "print");
index 86ed532490e69f5dd628aa654d85b18c3577f5ec..0b7c2211668ec950401dcd00f8533cd7f5af9404 100644 (file)
@@ -38,7 +38,7 @@ void ChimeraSlayer::print(ostream& out) {
                                        out << querySeqs[i]->getName() << "\tyes" << endl;
                                }else {
                                        out << querySeqs[i]->getName() << "\tno" << endl;
-                                       mothurOut(querySeqs[i]->getName() + "\tno"); mothurOutEndLine();
+                                       //mothurOut(querySeqs[i]->getName() + "\tno"); mothurOutEndLine();
                                }
 
                                printBlock(chimeraResults[i][0], out, i);
@@ -46,7 +46,7 @@ void ChimeraSlayer::print(ostream& out) {
                                out << endl;
                        }else{
                                out << querySeqs[i]->getName() << "\tno" << endl;
-                               mothurOut(querySeqs[i]->getName() + "\tno"); mothurOutEndLine();
+                               //mothurOut(querySeqs[i]->getName() + "\tno"); mothurOutEndLine();
                        }
                }
                                
@@ -212,8 +212,6 @@ void ChimeraSlayer::getChimeras() {
                if (seqMask != "") {
                        delete decalc; 
                }
-
-                       
        }
        catch(exception& e) {
                errorOut(e, "ChimeraSlayer", "getChimeras");