]> git.donarmstrong.com Git - mothur.git/blobdiff - slayer.h
sffinfo bug with flow grams right index when clipQualRight=0
[mothur.git] / slayer.h
index ea79727561fbfad37dfaf1478276e529b79df22b..eeefc62392b64cdb0eb5797cba1c994b27058f50 100644 (file)
--- a/slayer.h
+++ b/slayer.h
 
  
 #include "sequence.hpp"
+#include "chimera.h"
 
 /***********************************************************************/
 //This class was modeled after the chimeraSlayer written by the Broad Institute
 /***********************************************************************/
-struct data_struct { //this is crazy big...but follow original.
-       float divr_qla_qrb;
-       float divr_qlb_qra;
-       float qla_qrb;
-       float qlb_qra;
-       float qla;
-       float qrb;
-       float ab; 
-       float qa;
-       float qb; 
-       float lab; 
-       float rab; 
-       float qra; 
-       float qlb; 
-       int winLStart;
-       int winLEnd; 
-       int winRStart; 
-       int winREnd; 
-       Sequence querySeq; 
-       Sequence parentA;
-       Sequence parentB;
-       float bsa;
-       float bsb;
-       float bsMax;
-       float chimeraMax;
-       
-};
-/***********************************************************************/
-//sorts lowest to highest first by bsMax, then if tie by chimeraMax
-inline bool compareDataStruct(data_struct left, data_struct right){
-       if (left.bsMax < right.bsMax) { return true; }
-       else if (left.bsMax == right.bsMax) {
-               return (left.chimeraMax < right.chimeraMax);
-       }else { return false;   }
-} 
-/***********************************************************************/
 struct snps { 
        char queryChar;
        char parentAChar;
@@ -64,28 +29,31 @@ class Slayer {
 
        public:
                
-               Slayer(int, int, int, float);
+               Slayer(int, int, int, float, int, int, int);
                ~Slayer() {};
                
-               string getResults(Sequence*, vector<Sequence*>);
+               string getResults(Sequence, vector<Sequence>);
                vector<data_struct> getOutput()  {      return outputResults;                   }
                
                                
        private:
                
-               int windowSize, windowStep, parentFragmentThreshold;
+               int windowSize, windowStep, parentFragmentThreshold, iters, percentSNPSample, minBS;
                float divRThreshold; 
                vector<data_struct>  outputResults;
+               vector< map<int, int> > baseSpots;
+               Sequence myQuery;
                
-               void verticalFilter(vector<Sequence*>);
+               map<int, int> verticalFilter(Sequence&, Sequence&, Sequence&);
                float computePercentID(string, string, int, int);
                
-               vector<data_struct> runBellerophon(Sequence*, Sequence*, Sequence*);
+               vector<data_struct> runBellerophon(Sequence, Sequence, Sequence, map<int, int>&);
                vector<snps> getSNPS(string, string, string, int, int);
-               void bootstrapSNPS(vector<snps>, vector<snps>, float&, float&);
+               int bootstrapSNPS(vector<snps>, vector<snps>, float&, float&, int);
                float snpQA(vector<snps>);
                float snpQB(vector<snps>);
                float snpAB(vector<snps>);
+               MothurOut* m;
                                
 };