X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=matrixoutputcommand.h;h=b42cfb92c62a74fdb55b7902c3bfa9644c7359f7;hb=f06fdb807822f8e06db003ed809c87250905cfc8;hp=07743e5b4df6d867323c89c2acd78b241486bd00;hpb=cd37904452dc95b183ff313ff05720c562902487;p=mothur.git diff --git a/matrixoutputcommand.h b/matrixoutputcommand.h index 07743e5..b42cfb9 100644 --- a/matrixoutputcommand.h +++ b/matrixoutputcommand.h @@ -12,46 +12,55 @@ #include "command.hpp" #include "inputdata.h" #include "groupmap.h" -#include "readotu.h" #include "validcalculator.h" // aka. dist.shared() /* This command create a tree file for each similarity calculator at distance level, using various calculators to find the similiarity between groups. - The user can select the lines or labels they wish to use as well as the groups they would like included. + The user can select the labels they wish to use as well as the groups they would like included. They can also use as many or as few calculators as they wish. */ -class GlobalData; class MatrixOutputCommand : public Command { public: - MatrixOutputCommand(string); + MatrixOutputCommand(string); + MatrixOutputCommand(); ~MatrixOutputCommand(); - int execute(); - void help(); + + vector setParameters(); + string getCommandName() { return "dist.shared"; } + string getCommandCategory() { return "OTU-Based Approaches"; } + string getHelpString(); + string getCitation() { return "http://www.mothur.org/wiki/Dist.shared"; } + + int execute(); + void help() { m->mothurOut(getHelpString()); } private: - void printSims(ostream&); - void process(vector); + struct linePair { + int start; + int end; + }; + vector lines; + + void printSims(ostream&, vector< vector >&); + int process(vector); - GlobalData* globaldata; - ReadOTUFile* read; vector matrixCalculators; - vector< vector > simMatrix; + //vector< vector > simMatrix; InputData* input; - ValidCalculators* validCalculator; vector lookup; - string exportFileName; - int numGroups; + string exportFileName, output, sharedfile; + int numGroups, processors; ofstream out; bool abort, allLines; - set lines; //hold lines to be used set labels; //holds labels to be used - string outputFile, calc, groups, line, label; - vector Estimators, Groups; //holds estimators to be used - + string outputFile, calc, groups, label, outputDir; + vector Estimators, Groups, outputNames; //holds estimators to be used + int process(vector, string, string); + int driver(vector, int, int, vector< vector >&); };