]> git.donarmstrong.com Git - mothur.git/blob - collectcommand.h
broke up globaldata and moved error checking and help into commands
[mothur.git] / collectcommand.h
1 #ifndef COLLECTCOMMAND_H
2 #define COLLECTCOMMAND_H
3 /*
4  *  collectcommand.h
5  *  Dotur
6  *
7  *  Created by Sarah Westcott on 1/2/09.
8  *  Copyright 2009 Schloss Lab UMASS Amherst. All rights reserved.
9  *
10  */
11
12 #include "command.hpp"
13 #include "ordervector.hpp"
14 #include "inputdata.h"
15 #include "groupmap.h"
16 #include "collect.h"
17 #include "display.h"
18 #include "readotu.h"
19 #include "validcalculator.h"
20
21 /*The collect() command:
22         The collect command generates a collector's curve from the given file.  
23         The collect command can only be executed after a successful read.list, read.sabund or read.rabund command, with one exception. 
24         The collect command can be executed after a successful cluster command.  It will use the .list file from the output of the cluster.  
25         The collect command outputs a file for each estimator you choose to use.  The collect command parameters are label, line, freq, single, abund.  
26         No parameters are required, but you may not use both the line and label  parameters at the same time.  
27         The collect command should be in the following format: collect(label=yourLabel, line=yourLines, freq=yourFreq, single=yourEstimators, abund=yourAbund). 
28         example collect(label=unique-.01-.03, line=0,5,10, freq=10, single=collect-chao-ace-jack).  
29         The default values for  freq is 100, for abund is 10, and single are collect-chao-ace-jack-bootstrap-shannon-npshannon-simpson.  
30         The valid single estimators are: collect-chao-ace-jack-bootstrap-shannon-npshannon-simpson. 
31         The label and line parameters are used to analyze specific lines in your input. */
32
33
34
35 class GlobalData;
36
37 class CollectCommand : public Command {
38         
39 public:
40         CollectCommand(string); 
41         ~CollectCommand();
42         int execute();  
43         void help();
44         
45 private:
46         GlobalData* globaldata;
47         ReadOTUFile* read;
48         OrderVector* order;
49         OrderVector* lastOrder;
50         InputData* input;
51         Collect* cCurve;
52         ValidCalculators* validCalculator;
53         vector<Display*> cDisplays;
54         int freq, abund, size;
55         OptionParser* parser;
56         map<string, string> parameters;
57         map<string, string>::iterator it;
58         bool abort, allLines;
59         set<int> lines; //hold lines to be used
60         set<string> labels; //holds labels to be used
61         string line, label, calc;
62         vector<string>  Estimators;
63
64
65 };
66
67 #endif