]> git.donarmstrong.com Git - mothur.git/blobdiff - treegroupscommand.h
sffinfo bug with flow grams right index when clipQualRight=0
[mothur.git] / treegroupscommand.h
index 6790afb73984377c1aba8f6488a3cf1c2e544280..36c852bd8ef545894b9aa00245064eb112e236c6 100644 (file)
@@ -15,7 +15,7 @@
 #include "groupmap.h"
 #include "validcalculator.h"
 #include "tree.h"
-#include "treemap.h"
+#include "counttable.h"
 #include "readmatrix.hpp"
 #include "readcolumn.h"
 #include "readphylip.h"
@@ -78,8 +78,9 @@ public:
        vector<string> setParameters();
        string getCommandName()                 { return "tree.shared";                         }
        string getCommandCategory()             { return "OTU-Based Approaches";        }
-       string getOutputFileNameTag(string, string);
+       
        string getHelpString(); 
+    string getOutputPattern(string);   
        string getCitation() { return "http://www.mothur.org/wiki/Tree.shared"; }
        string getDescription()         { return "generate a tree file that describes the dissimilarity among groups"; }
 
@@ -104,13 +105,13 @@ private:
        
        NameAssignment* nameMap;
        ListVector* list;
-       TreeMap* tmap;
+       CountTable* ct;
        Tree* t;
     InputData* input;
        vector<Calculator*> treeCalculators;
        vector<SharedRAbundVector*> lookup;
        string lastLabel;
-       string format, groupNames, filename, sharedfile, inputfile;
+       string format, groupNames, filename, sharedfile, countfile, inputfile;
        int numGroups, subsampleSize, iters, processors;
        ofstream out;
        float precision, cutoff;
@@ -138,6 +139,7 @@ struct treeSharedData {
        unsigned long long start;
        unsigned long long end;
        MothurOut* m;
+    int count;
        
        treeSharedData(){}
        treeSharedData(MothurOut* mout, unsigned long long st, unsigned long long en, vector<string> est, vector<SharedRAbundVector*> lu) {
@@ -146,6 +148,7 @@ struct treeSharedData {
                end = en;
         Estimators = est;
         thisLookup = lu;
+        count=0;
        }
 };
 /**************************************************************************************************/
@@ -248,6 +251,8 @@ static DWORD WINAPI MyTreeSharedThreadFunction(LPVOID lpParam){
                vector<SharedRAbundVector*> subset;
                for (int k = pDataArray->start; k < pDataArray->end; k++) { // pass cdd each set of groups to compare
                        
+            pDataArray->count++;
+            
                        for (int l = 0; l < k; l++) {
                                
                                if (k != l) { //we dont need to similiarity of a groups to itself