X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=mothurmetastats.h;fp=mothurmetastats.h;h=4d6cf9166816f9f775e97eedc8a3231ec6daecd8;hb=0caf3fbabaa3ece404f8ce77f4c883dc5b1bf1dc;hp=0000000000000000000000000000000000000000;hpb=1b73ff67c83892a025e597dabd9df6fe7b58206a;p=mothur.git diff --git a/mothurmetastats.h b/mothurmetastats.h new file mode 100644 index 0000000..4d6cf91 --- /dev/null +++ b/mothurmetastats.h @@ -0,0 +1,49 @@ +#ifndef MOTHUR_METASTATS +#define MOTHUR_METASTATS + +/* + * mothurmetastats.h + * Mothur + * + * Created by westcott on 7/6/11. + * Copyright 2011 Schloss Lab. All rights reserved. + * + */ + + +#include "mothurout.h" + +class MothurMetastats { + + public: + MothurMetastats(double, int); //threshold, numPermutations + ~MothurMetastats(); + + int runMetastats(string, vector< vector >&, int); //outputFileName, data, secondGroupingStart + + private: + MothurOut* m; + int row, column, numPermutations, secondGroupingStart; + double threshold; + + vector permuted_pvalues(vector< vector >&, vector&, vector< vector >&); + vector permute_and_calc_ts(vector< vector >&); + + int start(vector&, int, vector&, vector< vector >&); //Find the initial values for the matrix + int meanvar(vector&, int, vector&); + int testp(vector&, vector&, vector&, int, vector&, vector&); + int permute_matrix(vector&, vector&, int, vector&, vector&, vector&); + int permute_array(vector&); + int calc_twosample_ts(vector&, int, vector&, vector&, vector&); + double smoothSpline(vector&, vector&, int); + vector calc_qvalues(vector&); + vector sknot1(double*, int); + int nkn(int); + int OrderPValues(int, int, vector&, vector&); + int swapElements(int, int, vector&, vector&); + vector getSequence(int, int, int); + +}; + +#endif +