]> git.donarmstrong.com Git - mothur.git/blob - clustersplitcommand.h
added command descriptions
[mothur.git] / clustersplitcommand.h
1 #ifndef CLUSTERSPLITCOMMAND_H
2 #define CLUSTERSPLITCOMMAND_H
3
4 /*
5  *  clustersplitcommand.h
6  *  Mothur
7  *
8  *  Created by westcott on 5/19/10.
9  *  Copyright 2010 Schloss Lab. All rights reserved.
10  *
11  */
12  
13 #include "command.hpp"
14 #include "rabundvector.hpp"
15 #include "sabundvector.hpp"
16 #include "listvector.hpp"
17 #include "cluster.hpp"
18 #include "sparsematrix.hpp"
19
20
21 class ClusterSplitCommand : public Command {
22         
23 public:
24         ClusterSplitCommand(string);
25         ClusterSplitCommand();
26         ~ClusterSplitCommand() {}
27         
28         vector<string> setParameters();
29         string getCommandName()                 { return "cluster.split";               }
30         string getCommandCategory()             { return "Clustering";                  }
31         string getHelpString(); 
32         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.split"; }
33         string getDescription()         { return "splits your sequences by distance or taxonomy then clusters into OTUs"; }
34         
35         int execute(); 
36         void help() { m->mothurOut(getHelpString()); }  
37
38 private:
39         vector<int> processIDS;   //processid
40         vector<string> outputNames;
41         
42         string method, fileroot, tag, outputDir, phylipfile, columnfile, namefile, distfile, format, showabund, timing, splitmethod, taxFile, fastafile;
43         double cutoff, splitcutoff;
44         int precision, length, processors, taxLevelCutoff;
45         bool print_start, abort, hard, large;
46         time_t start;
47         ofstream outList, outRabund, outSabund;
48         
49         void printData(ListVector*);
50         int createProcesses(vector < vector < map<string, string> > >);
51         vector<string> cluster(vector< map<string, string> >, set<string>&);
52         int mergeLists(vector<string>, map<float, int>, ListVector*);
53         map<float, int> completeListFile(vector<string>, string, set<string>&, ListVector*&);
54         int createMergedDistanceFile(vector< map<string, string> >);
55 };
56
57 #endif
58