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
|
#ifndef ANOSIMCOMMAND_H
#define ANOSIMCOMMAND_H
/*
* anosimcommand.h
* mothur
*
* Created by westcott on 2/14/11.
* Copyright 2011 Schloss Lab. All rights reserved.
*
*/
#include "command.hpp"
class DesignMap;
class AnosimCommand : public Command {
public:
AnosimCommand(string);
~AnosimCommand(){}
vector<string> setParameters();
string getCommandName() { return "anosim"; }
string getCommandCategory() { return "Hypothesis Testing"; }
string getHelpString();
string getOutputPattern(string);
string getCitation() { return "Clarke, K. R. (1993). Non-parametric multivariate analysis of changes in community structure. _Australian Journal of Ecology_ 18, 117-143.\nhttp://www.mothur.org/wiki/Anosim"; }
string getDescription() { return "analysis of similarity"; }
int execute();
void help() { m->mothurOut(getHelpString()); }
private:
bool abort;
DesignMap* designMap;
string inputDir, designFileName, phylipFileName;
vector<vector<double> > convertToRanks(vector<vector<double> >);
double calcR(vector<vector<double> >, map<string, vector<int> >);
map<string, vector<int> > getRandomizedGroups(map<string, vector<int> >);
double runANOSIM(ofstream&, vector<vector<double> >, map<string, vector<int> >, double);
vector< vector<double> > distanceMatrix;
vector<string> outputNames;
int iters;
double experimentwiseAlpha;
vector< vector<string> > namesOfGroupCombos;
};
#endif
|