]> git.donarmstrong.com Git - mothur.git/blobdiff - parselistcommand.cpp
changed read.shared to read.list and incorporated the shared and parselist commands...
[mothur.git] / parselistcommand.cpp
index 8a848e768fd5c4c2775bec636be6acf64dd5d2ac..451a375d4d705d2831f790fc259a28882e52c393 100644 (file)
@@ -27,12 +27,7 @@ ParseListCommand::ParseListCommand(){
                }
                
                //set fileroot
-               if(globaldata->getFileRoot() != ""){
-                       fileroot = globaldata->getFileRoot();
-               }
-               else{
-                       fileroot = getRootName(globaldata->getDistFile());
-               }
+               fileroot = getRootName(globaldata->getListFile());
                
                //open output list files
                for (i=0; i<groupMap->getNumGroups(); i++) {//opens an output file for each group
@@ -130,6 +125,10 @@ int ParseListCommand::execute(){
                                }
                                list = input->getListVector();
                        }
+                       
+                       //set groupmap for .shared commands
+                       globaldata->gGroupmap = groupMap; 
+                       
                        return 0;
        }
        catch(exception& e) {
@@ -146,7 +145,6 @@ int ParseListCommand::execute(){
 
 ParseListCommand::~ParseListCommand(){
        delete list;
-       delete groupMap;
        delete input;
        delete read;    
 }