]> git.donarmstrong.com Git - mothur.git/blob - distancecommand.h
446be04a2a3972976b7e67aba9a97cb277d928a8
[mothur.git] / distancecommand.h
1 #ifndef DISTANCECOMMAND_H
2 #define DISTANCECOMMAND_H
3
4 /*
5  *  distancecommand.h
6  *  Mothur
7  *
8  *  Created by Sarah Westcott on 5/7/09.
9  *  Copyright 2009 Schloss Lab UMASS Amherst. All rights reserved.
10  *
11  */
12
13 #include "mothur.h"
14 #include "command.hpp"
15 #include "globaldata.hpp"
16 #include "validcalculator.h"
17 #include "dist.h"
18 #include "sequencedb.h"
19
20 struct linePair {
21         int start;
22         int end;
23 };
24
25 class DistanceCommand : public Command {
26
27 public:
28         DistanceCommand(string);        
29         ~DistanceCommand() {};
30         int execute();  
31         void help();
32         
33 private:
34         GlobalData* globaldata;
35         ValidCalculators* validCalculator;
36         Dist* distCalculator;
37         SequenceDB* seqDB;
38         ofstream out, outFile;
39         ifstream in;
40         string countends, phylip, fastafile, calc;
41         int processors;
42         float cutoff;
43         map<int, int> processIDS;   //end line, processid
44         map<int, int>::iterator it;
45         vector<linePair*> lines;
46         
47         OptionParser* parser;
48         map<string, string> parameters;
49         map<string, string>::iterator it2;
50         bool abort;
51         vector<string>  Estimators; //holds estimators to be used
52         
53         void appendFiles(string, string);
54         void createProcesses(string);
55         int driver(Dist*, SequenceDB*, int, int, string, float);
56
57 };
58
59 #endif
60
61
62