]> git.donarmstrong.com Git - mothur.git/blobdiff - clustercommand.h
working on adding count file to mgcluster
[mothur.git] / clustercommand.h
index 37b9edb80224de6d7b7be0f722152e0bdd782b11..7349961e252104c93cf26942d79b44f11ba7c0f5 100644 (file)
@@ -10,7 +10,6 @@
  */
 
 #include "command.hpp"
-#include "globaldata.hpp"
 #include "rabundvector.hpp"
 #include "sabundvector.hpp"
 #include "listvector.hpp"
@@ -18,7 +17,6 @@
 #include "sparsematrix.hpp"
 
 /* The cluster() command:
-       The cluster command can only be executed after a successful read.phylip or read.column command.   
        The cluster command outputs a .list , .rabund and .sabund files.  
        The cluster command parameter options are method, cuttoff and precision. No parameters are required.  
        The cluster command should be in the following format: cluster(method=yourMethod, cutoff=yourCutoff, precision=yourPrecision).  
        The cluster() command outputs three files *.list, *.rabund, and *.sabund.   */
 
 
-class GlobalData;
-
 class ClusterCommand : public Command {
        
 public:
-       ClusterCommand(string); 
+       ClusterCommand(string);
+       ClusterCommand();
        ~ClusterCommand();
-       int execute();  
-       void help();
+       
+       vector<string> setParameters();
+       string getCommandName()                 { return "cluster";             }
+       string getCommandCategory()             { return "Clustering";  }
+       string getOutputFileNameTag(string, string);
+       string getHelpString(); 
+       string getCitation() { return "Schloss PD, Westcott SL (2011). Assessing and improving methods used in OTU-based approaches for 16S rRNA gene sequence analysis. Appl Environ Microbiol. \nhttp://www.mothur.org/wiki/Cluster"; }
+       string getDescription()         { return "cluster your sequences into OTUs using a distance matrix"; }
+       
+       int execute(); 
+       void help() { m->mothurOut(getHelpString()); }  
        
 private:
-       GlobalData* globaldata;
        Cluster* cluster;
        SparseMatrix* matrix;
        ListVector* list;
        RAbundVector* rabund;
        RAbundVector oldRAbund;
        ListVector oldList;
-       OptionParser* parser;
-       map<string, string> parameters;
-       map<string, string>::iterator it;
-       bool abort;
 
-       string method, fileroot, tag;
+       bool abort, hard, sim;
+
+       string method, fileroot, tag, outputDir, phylipfile, columnfile, namefile, format, distfile;
        double cutoff;
+       string showabund, timing;
        int precision, length;
        ofstream sabundFile, rabundFile, listFile;
+
+       bool print_start;
+       time_t start;
+       unsigned long loops;
        
        void printData(string label);
+       vector<string> outputNames;
 };
 
 #endif