X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=qualityscores.h;h=a802636fd364071ab15aa84c148ebb38fead14b4;hb=250e3b11b1c9c1e1ad458ab6c7e71ac2e67e11d9;hp=8f2105a1d095bfe94502d28ae387b89e8da9ed7c;hpb=bdb5d82e2a73829b4e1fa42656ad9bcb57e3e948;p=mothur.git diff --git a/qualityscores.h b/qualityscores.h index 8f2105a..a802636 100644 --- a/qualityscores.h +++ b/qualityscores.h @@ -10,6 +10,8 @@ * */ +//DataStructure for a quality file. + #include "mothur.h" #include "mothurout.h" @@ -20,27 +22,34 @@ class QualityScores { public: QualityScores(); - QualityScores(ifstream&, int); + QualityScores(ifstream&); string getName(); + int getLength(){ return (int)qScores.size(); } + vector getQualityScores() { return qScores; } void printQScores(ofstream&); void trimQScores(int, int); void flipQScores(); bool stripQualThreshold(Sequence&, double); - bool stripQualRollingAverage(Sequence&, double); - bool stripQualWindowAverage(Sequence&, int, int, double); - bool cullQualAverage(Sequence&, double); + bool stripQualRollingAverage(Sequence&, double, bool); + bool stripQualWindowAverage(Sequence&, int, int, double, bool); + bool cullQualAverage(Sequence&, double, bool); void updateQScoreErrorMap(map >&, string, int, int, int); void updateForwardMap(vector >&, int, int, int); void updateReverseMap(vector >&, int, int, int); + void setName(string n); + void setScores(vector qs) { qScores = qs; seqLength = qScores.size(); } + vector getScores() { return qScores; } private: - double calculateAverage(); + double calculateAverage(bool); MothurOut* m; vector qScores; string seqName; int seqLength; + + string getSequenceName(ifstream&); }; /**************************************************************************************************/