]> git.donarmstrong.com Git - mothur.git/blobdiff - treegroupscommand.cpp
working on nmds command
[mothur.git] / treegroupscommand.cpp
index a36e599fb3b04c01d2651423382566a26e7ac6d7..626659501a531db80f5193bef33e88793414a874 100644 (file)
@@ -34,6 +34,8 @@ vector<string> TreeGroupCommand::getValidParameters(){
 //**********************************************************************************************************************
 TreeGroupCommand::TreeGroupCommand(){  
        try {
+               abort = true;
+               globaldata = GlobalData::getInstance();
                //initialize outputTypes
                vector<string> tempOutNames;
                outputTypes["tree"] = tempOutNames;
@@ -667,6 +669,21 @@ int TreeGroupCommand::process(vector<SharedRAbundVector*> thisLookup) {
                                                }
                                        }
                                        
+                                       //createdistance file from simMatrix
+                                       /*string o = outputDir + m->getRootName(m->getSimpleName(globaldata->inputFileName)) + treeCalculators[i]->getName() + "." + thisLookup[0]->getLabel() + ".dist";
+                                       ofstream outDist;
+                                       m->openOutputFile(o, outDist);
+                                       outDist << simMatrix.size() << endl;
+                                       for (int k = 0; k < simMatrix.size(); k++) {
+                                               outDist << thisLookup[k]->getGroup() << '\t';
+                                               for (int l = 0; l < k; l++) {
+                                                       outDist << (1.0-simMatrix[k][l]) << '\t';
+                                               }
+                                               outDist << endl;
+                                       }
+                                       outDist.close();*/
+
+                                       
                                        if (m->control_pressed) { return 1; }
                                        //creates tree from similarity matrix and write out file
                                        createTree();