1 #ifndef CLASSIFYOTUSCOMMAND_H
2 #define CLASSIFYOTUSCOMMAND_H
8 * Created by westcott on 6/1/10.
9 * Copyright 2010 Schloss Lab. All rights reserved.
13 #include "command.hpp"
14 #include "listvector.hpp"
15 #include "inputdata.h"
16 #include "counttable.h"
19 class ClassifyOtuCommand : public Command {
22 ClassifyOtuCommand(string);
24 ~ClassifyOtuCommand() {}
26 vector<string> setParameters();
27 string getCommandName() { return "classify.otu"; }
28 string getCommandCategory() { return "Phylotype Analysis"; }
30 string getHelpString();
31 string getOutputPattern(string);
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 77:3219.\nhttp://www.mothur.org/wiki/Classify.otu"; }
33 string getDescription() { return "find the concensus taxonomy for each OTU"; }
36 void help() { m->mothurOut(getHelpString()); }
43 string listfile, namefile, taxfile, label, outputDir, refTaxonomy, groupfile, basis, countfile;
44 bool abort, allLines, probs, persample;
46 set<string> labels; //holds labels to be used
47 vector<string> outputNames, groups;
48 map<string, string> nameMap;
49 map<string, string> taxMap;
51 int process(ListVector*);
52 string addUnclassifieds(string, int);
53 vector<string> findConsensusTaxonomy(vector<string>, int&, string&); // returns the name of the "representative" taxonomy of given bin