else {
userGroups = "unique." + groups;
m->splitAtDash(groups, Groups);
+ if (Groups.size() > 4) { userGroups = "unique.selected_groups"; } //if too many groups then the filename becomes too big.
}
groups = validParameter.validFile(parameters, "sharedgroups", false);
else {
userGroups = groups;
m->splitAtDash(groups, Groups);
+ if (Groups.size() > 4) { userGroups = "selected_groups"; } //if too many groups then the filename becomes too big.
unique = false;
}
userGroups = "unique.";
for(int i = 0; i < Groups.size(); i++) { userGroups += Groups[i] + "-"; }
userGroups = userGroups.substr(0, userGroups.length()-1);
+ if (Groups.size() > 4) { userGroups = "unique.selected_groups"; } //if too many groups then the filename becomes too big.
}else{
//sanity check for group names
SharedUtil util;
int num = 0;
//go through each bin, find out if shared
+ vector<string> binLabels = shared->getLabels();
for (int i = 0; i < shared->getNumBins(); i++) {
if (m->control_pressed) { outNames.close(); m->mothurRemove(outputFileNames); return 0; }
//find group
string seqGroup = groupMap->getGroup(name);
if (output != "accnos") {
- namesOfSeqsInThisBin.push_back((name + "|" + seqGroup + "|" + toString(i+1)));
+ namesOfSeqsInThisBin.push_back((name + "|" + seqGroup + "|" + binLabels[i]));
}else { namesOfSeqsInThisBin.push_back(name); }
if (seqGroup == "not found") { m->mothurOut(name + " is not in your groupfile. Please correct."); m->mothurOutEndLine(); exit(1); }
userGroups = "unique.";
for(int i = 0; i < Groups.size(); i++) { userGroups += Groups[i] + "-"; }
userGroups = userGroups.substr(0, userGroups.length()-1);
+ if (Groups.size() > 4) { userGroups = "unique.selected_groups"; } //if too many groups then the filename becomes too big.
}else {
//sanity check for group names
SharedUtil util;
for(int j = 0; j < lookup.size(); j++) {
string seqGroup = lookup[j]->getGroup();
- string name = m->currentBinLabels[i];
+ string name = m->currentSharedBinLabels[i];
if (lookup[j]->getAbundance(i) != 0) {
if (output != "accnos") {