File: bootstrapsharedcommand.h

package info (click to toggle)
mothur 1.24.1-1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 7,868 kB
  • sloc: cpp: 110,948; ansic: 2,037; fortran: 665; makefile: 74; sh: 59
file content (71 lines) | stat: -rw-r--r-- 1,751 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
#ifndef BOOTSTRAPSHAREDCOMMAND_H
#define BOOTSTRAPSHAREDCOMMAND_H

/*
 *  bootstrapsharedcommand.h
 *  Mothur
 *
 *  Created by Sarah Westcott on 4/16/09.
 *  Copyright 2009 Schloss Lab UMASS Amherst. All rights reserved.
 *
 */
 
#include "command.hpp"
#include "sharedordervector.h"
#include "inputdata.h"
#include "groupmap.h"
#include "validcalculator.h"
#include "tree.h"
#include "treemap.h"
#include "sharedutilities.h"
#include "consensuscommand.h"

class BootSharedCommand : public Command {
	
public:
	BootSharedCommand(string);	
	BootSharedCommand();
	~BootSharedCommand();
	
	vector<string> setParameters();
	string getCommandName()			{ return "bootstrap.shared";	}
	string getCommandCategory()		{ return "Hidden";				}
	string getHelpString();	
	string getCitation() { return "no citation"; }
	string getDescription()		{ return "bootstrap.shared"; }

	
	int execute(); 
	void help() { m->mothurOut(getHelpString()); }	
	
private:
	int createTree(ostream*, Tree*);
	void printSims();
	int process(SharedOrderVector*);
	
	SharedUtil* util;
	TreeMap* tmap;
	Tree* t;
	Tree* tempTree;
	ConcensusCommand* consensus;
	vector< vector<Tree*> > trees;  //a vector of trees for each calculator chosen
	vector<Calculator*> treeCalculators;
	vector<ofstream*> out;
	vector< vector<float> > simMatrix;
	map<int, int> index;  //maps row in simMatrix to vector index in the tree	
	InputData* input;
	ValidCalculators* validCalculator;
	SharedOrderVector* order;
	vector<SharedRAbundVector*> lookup;

	bool abort, allLines;
	set<string> labels; //holds labels to be used
	string outputFile, calc, groups, label, outputDir, sharedfile;
	int numGroups, iters;
	vector<string>  Estimators, Groups, outputNames; //holds estimators to be used
};
	
	
#endif