]> git.donarmstrong.com Git - mothur.git/blobdiff - blastdb.cpp
added warning about merging with something above cutoff to cluster. working on chimeras
[mothur.git] / blastdb.cpp
index b139f3eb7a47bcc86f0920bdc0fc22bad368816a..396a6b4b91c4496b80dfc3009cdda4a0f34b12e6 100644 (file)
@@ -72,6 +72,23 @@ vector<int> BlastDB::findClosestSequences(Sequence* seq, int n) {
                }
                m8FileHandle.close();
                
+               string root = dbFileName;
+               string temp = dbFileName + ".nsq";
+               remove(temp.c_str());   
+               temp = dbFileName + ".nsi";
+               remove(temp.c_str());
+               
+               temp = dbFileName + ".nsd";
+               remove(temp.c_str());   
+
+               temp = dbFileName + ".nin";
+               remove(temp.c_str());   
+
+               temp = dbFileName + ".nhr";
+               remove(temp.c_str());   
+       
+
+               
                return topMatches;
        }
        catch(exception& e) {
@@ -101,7 +118,7 @@ vector<int> BlastDB::findClosestMegaBlast(Sequence* seq, int n) {
                system(blastCommand.c_str());
                
                ifstream m8FileHandle;
-               openInputFile(blastFileName, m8FileHandle);
+               openInputFile(blastFileName, m8FileHandle, "no error");
        
                string dummy;
                int templateAccession;
@@ -115,9 +132,10 @@ vector<int> BlastDB::findClosestMegaBlast(Sequence* seq, int n) {
                        
                        gobble(m8FileHandle);
                        topMatches.push_back(templateAccession);
+//cout << templateAccession << endl;
                }
                m8FileHandle.close();
-               
+//cout << "\n\n" ;             
                return topMatches;
        }
        catch(exception& e) {