]> git.donarmstrong.com Git - mothur.git/blobdiff - cluster.hpp
adding mothurout.h and .cpp to repo
[mothur.git] / cluster.hpp
index 685c843c0199b73083f7eb3a17693b33fe1a4d36..72d3611a093296b3dc18d9ddb7bf12d0a0a9a0e5 100644 (file)
@@ -4,6 +4,7 @@
 
 #include "mothur.h"
 #include "sparsematrix.hpp"
+#include "mothurout.h"
 
 class RAbundVector;
 class ListVector;
@@ -13,7 +14,7 @@ typedef vector<MatData> MatVec;
 class Cluster {
        
 public:
-       Cluster(RAbundVector*, ListVector*, SparseMatrix*, float);
+       Cluster(RAbundVector*, ListVector*, SparseMatrix*, float, string);
     virtual void update(double&);                              
        virtual string getTag() = 0;
        virtual void setMapWanted(bool m);  
@@ -39,19 +40,21 @@ protected:
        bool mapWanted;
        float cutoff;
        map<string, int> seq2Bin;
+       string method;
        
        vector<MatVec> seqVec;          // contains vectors of cells related to a certain sequence
        MatVec rowCells;
        MatVec colCells;
        ull nRowCells;
        ull nColCells;
+       MothurOut* m;
 };
 
 /***********************************************************************/
 
 class CompleteLinkage : public Cluster {
 public:
-       CompleteLinkage(RAbundVector*, ListVector*, SparseMatrix*, float);
+       CompleteLinkage(RAbundVector*, ListVector*, SparseMatrix*, float, string);
        bool updateDistance(MatData& colCell, MatData& rowCell);
        string getTag();
        
@@ -63,7 +66,7 @@ private:
 
 class SingleLinkage : public Cluster {
 public:
-       SingleLinkage(RAbundVector*, ListVector*, SparseMatrix*, float);
+       SingleLinkage(RAbundVector*, ListVector*, SparseMatrix*, float, string);
     void update();
        bool updateDistance(MatData& colCell, MatData& rowCell);
        string getTag();
@@ -76,7 +79,7 @@ private:
 
 class AverageLinkage : public Cluster {
 public:
-       AverageLinkage(RAbundVector*, ListVector*, SparseMatrix*, float);
+       AverageLinkage(RAbundVector*, ListVector*, SparseMatrix*, float, string);
        bool updateDistance(MatData& colCell, MatData& rowCell);
        string getTag();