if (itGroup != g.end()) {
groupCounts[indexGroupMap[itGroup->second]] = 1;
totalGroups[indexGroupMap[itGroup->second]]++;
- }else { m->mothurOut("[ERROR]: Your group file does not contain " + seqName + ". Please correct."); m->mothurOutEndLine(); }
+ }else {
+ //look for it in names of groups to see if the user accidently used the wrong file
+ if (m->inUsersGroups(seqName, groups)) {
+ m->mothurOut("[WARNING]: Your group or design file contains a group named " + seqName + ". Perhaps you are used a group file instead of a design file? A common cause of this is using a tree file that relates your groups (created by the tree.shared command) with a group file that assigns sequences to a group."); m->mothurOutEndLine();
+ }
+ m->mothurOut("[ERROR]: Your group file does not contain " + seqName + ". Please correct."); m->mothurOutEndLine();
+ }
map<string, int>::iterator it2 = indexNameMap.find(seqName);
if (it2 == indexNameMap.end()) {
if (hasGroups) {
map<string, int>::iterator it = indexNameMap.find(seqName);
if (it == indexNameMap.end()) {
+ //look for it in names of groups to see if the user accidently used the wrong file
+ if (m->inUsersGroups(seqName, groups)) {
+ m->mothurOut("[WARNING]: Your group or design file contains a group named " + seqName + ". Perhaps you are used a group file instead of a design file? A common cause of this is using a tree file that relates your groups (created by the tree.shared command) with a group file that assigns sequences to a group."); m->mothurOutEndLine();
+ }
m->mothurOut("[ERROR]: " + seqName + " is not in your count table. Please correct.\n"); m->control_pressed = true;
}else {
temp = counts[it->second];
}else {
map<string, int>::iterator it2 = indexNameMap.find(seqName);
if (it2 == indexNameMap.end()) {
+ //look for it in names of groups to see if the user accidently used the wrong file
+ if (m->inUsersGroups(seqName, groups)) {
+ m->mothurOut("[WARNING]: Your group or design file contains a group named " + seqName + ". Perhaps you are used a group file instead of a design file? A common cause of this is using a tree file that relates your groups (created by the tree.shared command) with a group file that assigns sequences to a group."); m->mothurOutEndLine();
+ }
m->mothurOut("[ERROR]: seq " + seqName + " is not in your count table. Please correct.\n"); m->control_pressed = true;
}else {
return counts[it2->second][it->second];
}else {
map<string, int>::iterator it2 = indexNameMap.find(seqName);
if (it2 == indexNameMap.end()) {
+ //look for it in names of groups to see if the user accidently used the wrong file
+ if (m->inUsersGroups(seqName, groups)) {
+ m->mothurOut("[WARNING]: Your group or design file contains a group named " + seqName + ". Perhaps you are used a group file instead of a design file? A common cause of this is using a tree file that relates your groups (created by the tree.shared command) with a group file that assigns sequences to a group."); m->mothurOutEndLine();
+ }
m->mothurOut("[ERROR]: " + seqName + " is not in your count table. Please correct.\n"); m->control_pressed = true;
}else {
int oldCount = counts[it2->second][it->second];
map<string, int>::iterator it = indexNameMap.find(oldSeqName);
if (it == indexNameMap.end()) {
+ if (hasGroupInfo()) {
+ //look for it in names of groups to see if the user accidently used the wrong file
+ if (m->inUsersGroups(oldSeqName, groups)) {
+ m->mothurOut("[WARNING]: Your group or design file contains a group named " + oldSeqName + ". Perhaps you are used a group file instead of a design file? A common cause of this is using a tree file that relates your groups (created by the tree.shared command) with a group file that assigns sequences to a group."); m->mothurOutEndLine();
+ }
+ }
m->mothurOut("[ERROR]: " + oldSeqName + " is not in your count table. Please correct.\n"); m->control_pressed = true;
}else {
int index = it->second;
map<string, int>::iterator it = indexNameMap.find(seqName);
if (it == indexNameMap.end()) {
+ if (hasGroupInfo()) {
+ //look for it in names of groups to see if the user accidently used the wrong file
+ if (m->inUsersGroups(seqName, groups)) {
+ m->mothurOut("[WARNING]: Your group or design file contains a group named " + seqName + ". Perhaps you are used a group file instead of a design file? A common cause of this is using a tree file that relates your groups (created by the tree.shared command) with a group file that assigns sequences to a group."); m->mothurOutEndLine();
+ }
+ }
m->mothurOut("[ERROR]: " + seqName + " is not in your count table. Please correct.\n"); m->control_pressed = true;
}else {
return totals[it->second];
map<string, int>::iterator it = indexNameMap.find(seqName);
if (it == indexNameMap.end()) {
+ if (hasGroupInfo()) {
+ //look for it in names of groups to see if the user accidently used the wrong file
+ if (m->inUsersGroups(seqName, groups)) {
+ m->mothurOut("[WARNING]: Your group or design file contains a group named " + seqName + ". Perhaps you are used a group file instead of a design file? A common cause of this is using a tree file that relates your groups (created by the tree.shared command) with a group file that assigns sequences to a group."); m->mothurOutEndLine();
+ }
+ }
m->mothurOut("[ERROR]: " + seqName + " is not in your count table. Please correct.\n"); m->control_pressed = true;
}else { return it->second; }
total -= thisTotal;
indexNameMap.erase(it);
}else {
+ if (hasGroupInfo()) {
+ //look for it in names of groups to see if the user accidently used the wrong file
+ if (m->inUsersGroups(seqName, groups)) {
+ m->mothurOut("[WARNING]: Your group or design file contains a group named " + seqName + ". Perhaps you are used a group file instead of a design file? A common cause of this is using a tree file that relates your groups (created by the tree.shared command) with a group file that assigns sequences to a group."); m->mothurOutEndLine();
+ }
+ }
m->mothurOut("[ERROR]: Your count table contains does not include " + seqName + ", cannot remove."); m->mothurOutEndLine(); m->control_pressed = true;
}
try {
map<string, int>::iterator it = indexNameMap.find(seq1);
if (it == indexNameMap.end()) {
+ if (hasGroupInfo()) {
+ //look for it in names of groups to see if the user accidently used the wrong file
+ if (m->inUsersGroups(seq1, groups)) {
+ m->mothurOut("[WARNING]: Your group or design file contains a group named " + seq1 + ". Perhaps you are used a group file instead of a design file? A common cause of this is using a tree file that relates your groups (created by the tree.shared command) with a group file that assigns sequences to a group."); m->mothurOutEndLine();
+ }
+ }
m->mothurOut("[ERROR]: " + seq1 + " is not in your count table. Please correct.\n"); m->control_pressed = true;
}else {
map<string, int>::iterator it2 = indexNameMap.find(seq2);
if (it2 == indexNameMap.end()) {
+ if (hasGroupInfo()) {
+ //look for it in names of groups to see if the user accidently used the wrong file
+ if (m->inUsersGroups(seq2, groups)) {
+ m->mothurOut("[WARNING]: Your group or design file contains a group named " + seq2 + ". Perhaps you are used a group file instead of a design file? A common cause of this is using a tree file that relates your groups (created by the tree.shared command) with a group file that assigns sequences to a group."); m->mothurOutEndLine();
+ }
+ }
m->mothurOut("[ERROR]: " + seq2 + " is not in your count table. Please correct.\n"); m->control_pressed = true;
}else {
//merge data