*
*/
-#include <Carbon/Carbon.h>
-#include <iostream>
-#include <fstream>
-#include "globaldata.hpp"
#include "command.hpp"
#include "rabundvector.hpp"
#include "sabundvector.hpp"
#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();
+ ClusterCommand(string);
+ ClusterCommand();
~ClusterCommand();
- int execute();
+
+ vector<string> setParameters();
+ string getCommandName() { return "cluster"; }
+ string getCommandCategory() { return "Clustering"; }
+ string getHelpString();
+
+ int execute();
+ void help() { m->mothurOut(getHelpString()); }
private:
- GlobalData* globaldata;
Cluster* cluster;
SparseMatrix* matrix;
ListVector* list;
RAbundVector* rabund;
RAbundVector oldRAbund;
ListVector oldList;
-
- 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
\ No newline at end of file
+#endif