]> git.donarmstrong.com Git - mothur.git/commitdiff
removed comments
authorkiverson <kiverson@192.168.0.196>
Fri, 22 Jun 2012 19:12:47 +0000 (15:12 -0400)
committerkiverson <kiverson@192.168.0.196>
Fri, 22 Jun 2012 19:12:47 +0000 (15:12 -0400)
mgclustercommand.cpp
mgclustercommand.h

index 42f6d0ad72b7fcc35674b3734664f4c48b2e0fab..06f05192ad1e91a1c85b2de8e986039d82d5c375 100644 (file)
@@ -235,16 +235,16 @@ int MGClusterCommand::execute(){
                read = new ReadBlast(blastfile, cutoff, penalty, length, minWanted, hclusterWanted);
                read->read(nameMap);
         
-//        list = new ListVector(nameMap->getListVector());
-//        RAbundVector* rabund = NULL;
-//        
-//        if(large) {
-//            map<string, int> nameMapCounts = m->readNames(namefile);
-//            createRabund(nameMapCounts);
-//            rabund = &rav;
-//        }else {
-//            rabund = new RAbundVector(list->getRAbundVector());
-//        }
+        list = new ListVector(nameMap->getListVector());
+        RAbundVector* rabund = NULL;
+        
+        if(large) {
+            map<string, int> nameMapCounts = m->readNames(namefile);
+            createRabund(nameMapCounts);
+            rabund = &rav;
+        }else {
+            rabund = new RAbundVector(list->getRAbundVector());
+        }
         
                 
                list = new ListVector(nameMap->getListVector());
@@ -714,22 +714,22 @@ void MGClusterCommand::sortHclusterFiles(string unsortedDist, string unsortedOve
 }
 
 //**********************************************************************************************************************
-//
-//void MGClusterCommand::createRabund(map<string, int> nameMapCounts){
-//    try {
-//        //RAbundVector rav;
-//        map<string,int>::iterator it;
-//        //it = nameMapCounts.begin();
-//        //for(int i = 0; i < list->getNumBins(); i++) {   rav.push_back((*it).second); it++;    }
-//        for ( it=nameMapCounts.begin(); it!=nameMapCounts.end(); it++ ) {    rav.push_back( it->second );    }
-//        //return rav;
-//    }
-//    catch(exception& e) {
-//             m->errorOut(e, "MGClusterCommand", "createRabund");
-//             exit(1);
-//     }
-//    
-//}
+
+void MGClusterCommand::createRabund(map<string, int> nameMapCounts){
+    try {
+        //RAbundVector rav;
+        map<string,int>::iterator it;
+        //it = nameMapCounts.begin();
+        //for(int i = 0; i < list->getNumBins(); i++) {   rav.push_back((*it).second); it++;    }
+        for ( it=nameMapCounts.begin(); it!=nameMapCounts.end(); it++ ) {    rav.push_back( it->second );    }
+        //return rav;
+    }
+    catch(exception& e) {
+               m->errorOut(e, "MGClusterCommand", "createRabund");
+               exit(1);
+       }
+    
+}
 
 //**********************************************************************************************************************
 
index a727c973c5954052f577479eed1046142e2cc49a..96410bfc39f1a28140357cdf2ee9233fe5e51bc2 100644 (file)
@@ -47,7 +47,7 @@ private:
        HCluster* hcluster;
        ListVector* list;
        ListVector oldList;
-//    RAbundVector rav;
+        RAbundVector rav;
        vector<seqDist> overlapMatrix;
        vector<string> outputNames;
        
@@ -62,7 +62,7 @@ private:
        ListVector* mergeOPFs(map<string, int>, float);
        void sortHclusterFiles(string, string);
        vector<seqDist> getSeqs(ifstream&);
-//    void createRabund(map<string, int>);
+        void createRabund(map<string, int>);
 
 };