]> git.donarmstrong.com Git - mothur.git/blob - splitgroupscommand.h
added split.groups command
[mothur.git] / splitgroupscommand.h
1 #ifndef SPLITGROUPSCOMMAND_H
2 #define SPLITGROUPSCOMMAND_H
3
4 /*
5  *  splitgroupscommand.h
6  *  Mothur
7  *
8  *  Created by westcott on 9/20/10.
9  *  Copyright 2010 Schloss Lab. All rights reserved.
10  *
11  */
12
13
14 /* split.groups - given a group file, split sequences and names files in to separate files *.group1.fasta and .group1.names. */
15
16
17 #include "command.hpp"
18 #include "groupmap.h"
19 #include "sequence.hpp"
20
21 /***************************************************************************************/
22
23 class SplitGroupCommand : public Command {
24         
25 public:
26         SplitGroupCommand(string);      
27         ~SplitGroupCommand();
28         int execute();  
29         void help();
30
31         
32 private:
33         int readNames(); 
34         int splitFasta(); 
35         
36         vector<string> outputNames;
37         map<string, vector<string> > nameMap;
38         map<string, vector<string> >::iterator itNames;
39         GroupMap* groupMap;
40         
41         string outputDir, namefile, groupfile, groups, fastafile;
42         vector<string> Groups;
43         bool abort;
44 };
45
46 /***************************************************************************************/
47
48 #endif
49
50
51