]> git.donarmstrong.com Git - mothur.git/blobdiff - cluster.hpp
added warning about merging with something above cutoff to cluster. working on chimeras
[mothur.git] / cluster.hpp
index a6024e79d45a52274040a53cca4f8b32d9d2e998..6d7fc470e91eca8dae548ffb5594a4099a203f35 100644 (file)
@@ -13,8 +13,8 @@ typedef vector<MatData> MatVec;
 class Cluster {
        
 public:
-       Cluster(RAbundVector*, ListVector*, SparseMatrix*);
-    virtual void update();                             
+       Cluster(RAbundVector*, ListVector*, SparseMatrix*, float, string);
+    virtual void update(double&);                              
        virtual string getTag() = 0;
        virtual void setMapWanted(bool m);  
        virtual map<string, int> getSeqtoBin()  {  return seq2Bin;      }
@@ -37,7 +37,9 @@ protected:
        int smallCol;
        float smallDist;
        bool mapWanted;
+       float cutoff;
        map<string, int> seq2Bin;
+       string method;
        
        vector<MatVec> seqVec;          // contains vectors of cells related to a certain sequence
        MatVec rowCells;
@@ -50,7 +52,7 @@ protected:
 
 class CompleteLinkage : public Cluster {
 public:
-       CompleteLinkage(RAbundVector*, ListVector*, SparseMatrix*);
+       CompleteLinkage(RAbundVector*, ListVector*, SparseMatrix*, float, string);
        bool updateDistance(MatData& colCell, MatData& rowCell);
        string getTag();
        
@@ -62,7 +64,7 @@ private:
 
 class SingleLinkage : public Cluster {
 public:
-       SingleLinkage(RAbundVector*, ListVector*, SparseMatrix*);
+       SingleLinkage(RAbundVector*, ListVector*, SparseMatrix*, float, string);
     void update();
        bool updateDistance(MatData& colCell, MatData& rowCell);
        string getTag();
@@ -75,7 +77,7 @@ private:
 
 class AverageLinkage : public Cluster {
 public:
-       AverageLinkage(RAbundVector*, ListVector*, SparseMatrix*);
+       AverageLinkage(RAbundVector*, ListVector*, SparseMatrix*, float, string);
        bool updateDistance(MatData& colCell, MatData& rowCell);
        string getTag();