]> git.donarmstrong.com Git - mothur.git/blobdiff - readotucommand.cpp
fixed bug with hcluster
[mothur.git] / readotucommand.cpp
index 2e2bbc90baf0fbcfe9abb79b049c1cf2589edfe0..584eb8543d57dd5e5da10775b5ce684250d28229 100644 (file)
@@ -21,7 +21,7 @@ ReadOtuCommand::ReadOtuCommand(string option){
                
                else {
                        //valid paramters for this command
-                       string Array[] =  {"list","order","shared", "label","group","sabund", "rabund"};
+                       string Array[] =  {"list","order","shared", "label","group","sabund", "rabund","groups"};
                        vector<string> myArray (Array, Array+(sizeof(Array)/sizeof(string)));
                        
                        OptionParser parser(option);
@@ -66,6 +66,13 @@ ReadOtuCommand::ReadOtuCommand(string option){
                                groupMap->readMap();
                                globaldata->gGroupmap = groupMap;
                        }
+                       
+                       groups = validParameter.validFile(parameters, "groups", false);                 
+                       if (groups == "not found") { groups = ""; }
+                       else { 
+                               splitAtDash(groups, Groups);
+                               globaldata->Groups = Groups;
+                       }
 
                        //you are doing a list and group shared
                        if ((listfile != "") && (groupfile != "")) { globaldata->setFormat("shared"); }