+ ifstream in;
+ openInputFile(taxfile, in);
+ string name, tax;
+
+ bool wroteSomething = false;
+
+ while(!in.eof()){
+ if (m->control_pressed) { in.close(); out.close(); remove(outputFileName.c_str()); return 0; }
+
+ in >> name; //read from first column
+ in >> tax; //read from second column
+
+ //if this name is in the accnos file
+ if (names.count(name) == 0) {
+ wroteSomething = true;
+ out << name << '\t' << tax << endl;
+ }
+
+ gobble(in);
+ }
+ in.close();
+ out.close();
+
+ if (wroteSomething == false) {
+ m->mothurOut("Your file contains only sequences from the .accnos file."); m->mothurOutEndLine();
+ remove(outputFileName.c_str());
+ }else { outputNames.push_back(outputFileName); }
+
+ return 0;
+ }
+ catch(exception& e) {
+ m->errorOut(e, "RemoveSeqsCommand", "readTax");
+ exit(1);
+ }
+}