helpString += "The get.otus command should be in the following format: get.otus(accnos=yourAccnos, list=yourListFile, group=yourGroupFile, label=yourLabel).\n";
helpString += "Example get.otus(accnos=amazon.accnos, list=amazon.fn.list, group=amazon.groups, label=0.03).\n";
helpString += "or get.otus(groups=pasture, list=amazon.fn.list, amazon.groups, label=0.03).\n";
helpString += "The get.otus command should be in the following format: get.otus(accnos=yourAccnos, list=yourListFile, group=yourGroupFile, label=yourLabel).\n";
helpString += "Example get.otus(accnos=amazon.accnos, list=amazon.fn.list, group=amazon.groups, label=0.03).\n";
helpString += "or get.otus(groups=pasture, list=amazon.fn.list, amazon.groups, label=0.03).\n";
//check for required parameters
accnosfile = validParameter.validFile(parameters, "accnos", true);
if (accnosfile == "not open") { abort = true; }
//check for required parameters
accnosfile = validParameter.validFile(parameters, "accnos", true);
if (accnosfile == "not open") { abort = true; }
groupfile = validParameter.validFile(parameters, "group", true);
if (groupfile == "not open") { abort = true; }
groupfile = validParameter.validFile(parameters, "group", true);
if (groupfile == "not open") { abort = true; }
groupfile = m->getGroupFile();
if (groupfile != "") { m->mothurOut("Using " + groupfile + " as input file for the group parameter."); m->mothurOutEndLine(); }
else { m->mothurOut("You have no current group file and the group parameter is required."); m->mothurOutEndLine(); abort = true; }
groupfile = m->getGroupFile();
if (groupfile != "") { m->mothurOut("Using " + groupfile + " as input file for the group parameter."); m->mothurOutEndLine(); }
else { m->mothurOut("You have no current group file and the group parameter is required."); m->mothurOutEndLine(); abort = true; }
listfile = validParameter.validFile(parameters, "list", true);
if (listfile == "not open") { abort = true; }
listfile = validParameter.validFile(parameters, "list", true);
if (listfile == "not open") { abort = true; }
listfile = m->getListFile();
if (listfile != "") { m->mothurOut("Using " + listfile + " as input file for the list parameter."); m->mothurOutEndLine(); }
else { m->mothurOut("You have no current list file and the list parameter is required."); m->mothurOutEndLine(); abort = true; }
listfile = m->getListFile();
if (listfile != "") { m->mothurOut("Using " + listfile + " as input file for the list parameter."); m->mothurOutEndLine(); }
else { m->mothurOut("You have no current list file and the list parameter is required."); m->mothurOutEndLine(); abort = true; }
groups = validParameter.validFile(parameters, "groups", false);
if (groups == "not found") { groups = ""; }
groups = validParameter.validFile(parameters, "groups", false);
if (groups == "not found") { groups = ""; }
//make sure groups are valid
//takes care of user setting groupNames that are invalid or setting groups=all
SharedUtil* util = new SharedUtil();
//make sure groups are valid
//takes care of user setting groupNames that are invalid or setting groups=all
SharedUtil* util = new SharedUtil();
- util->setGroups(Groups, groupMap->namesOfGroups);
+ vector<string> gNamesOfGroups = groupMap->getNamesOfGroups();
+ util->setGroups(Groups, gNamesOfGroups);
+ groupMap->setNamesOfGroups(gNamesOfGroups);
//as long as you are not at the end of the file or done wih the lines you want
while((list != NULL) && (userLabels.size() != 0)) {
//as long as you are not at the end of the file or done wih the lines you want
while((list != NULL) && (userLabels.size() != 0)) {
if(labels.count(list->getLabel()) == 1){
processList(list, groupMap, out, outGroup, wroteSomething);
if(labels.count(list->getLabel()) == 1){
processList(list, groupMap, out, outGroup, wroteSomething);