]> git.donarmstrong.com Git - mothur.git/blob - splitabundcommand.h
modified calculators to use doubles, added numotu and fontsize parameters to heatmap...
[mothur.git] / splitabundcommand.h
1 #ifndef SPLITABUNDCOMMAND_H
2 #define SPLITABUNDCOMMAND_H
3
4 /*
5  *  splitabundcommand.h
6  *  Mothur
7  *
8  *  Created by westcott on 5/17/10.
9  *  Copyright 2010 Schloss Lab. All rights reserved.
10  *
11  */
12
13
14 /* split.abund - given a list or name file and a number (cutoff), make two files - *rare* and *abund* 
15 - where rare has data for otus that have fewer sequences than the cutoff and abund has data for otus 
16 that have as many or more sequences as the cutoff. 
17 also allow an option where a user can give a group file with the list or names file and split the group file into rare and abund. */
18
19
20 #include "command.hpp"
21 #include "groupmap.h"
22 #include "inputdata.h"
23 #include "listvector.hpp"
24
25 /***************************************************************************************/
26
27 class SplitAbundCommand : public Command {
28         
29 public:
30         SplitAbundCommand(string);      
31         ~SplitAbundCommand();
32         int execute();  
33         void help();
34
35         
36 private:
37         int splitList(ListVector*);
38         int splitNames(); //namefile
39         int writeNames(); 
40         int writeList(ListVector*); 
41         int writeAccnos(string); 
42         int parseGroup(string); 
43         int parseFasta(string); 
44         int readNamesFile(); //namefile
45         int createNameMap(ListVector*);
46         
47         vector<string> outputNames;
48         ListVector* list;
49         GroupMap* groupMap;
50         InputData* input;
51         
52         string outputDir, listfile, namefile, groupfile, label, groups, fastafile, inputFile;
53         set<string> labels, rareNames, abundNames;
54         vector<string> Groups;
55         bool abort, allLines, accnos;
56         int cutoff;
57         //map<string, bool> wroteListFile;
58         map<string, string> nameMap;
59         
60         
61
62 };
63
64 /***************************************************************************************/
65
66 #endif
67
68