#include <Match.h>
Public Types | |
| typedef multiset< M8MatchEX *, ltMatchQueryBeginPtr > ::iterator | bestiterator |
| typedef multiset< M8MatchEX *, ltMatchQueryBeginPtr > ::reverse_iterator | bestreverse_iterator |
Public Member Functions | |
| ~Linkmatch () | |
| Linkmatch (Tblastn &tb) | |
| template<class ForwardIterator> | |
| M8MatchEX * | bestModel (ForwardIterator first, ForwardIterator last, const Match &box) |
| M8MatchEX * | bestModel (const Match &sec) |
| void | bestModel (vector< Boxchain * > &topmodels) |
| void | showBest (ostream &ous) const |
| void | show_best (ostream &ous) const |
| void | show_end2match (ostream &ous) const |
| void | show_start2match (ostream &ous) const |
| void | show_sections (ostream &ous) const |
| void | removeChain (M8MatchEX *p, Match &box) |
Private Member Functions | |
| void | cleanUpBest (bestiterator bi) |
Private Attributes | |
| set< int > | xpoints |
| multimap< int, M8MatchEX * > | start2match |
| multimap< int, M8MatchEX * > | end2match |
| multiset< M8MatchEX *, ltMatchQueryBeginPtr > | best |
| vector< Match > | sections |
This is the key class implementing the chaining algorithm.
| typedef multiset<M8MatchEX*, ltMatchQueryBeginPtr>::iterator Linkmatch::bestiterator |
| typedef multiset<M8MatchEX*, ltMatchQueryBeginPtr>::reverse_iterator Linkmatch::bestreverse_iterator |
| Linkmatch::~Linkmatch | ( | ) |
References start2match.
| Linkmatch::Linkmatch | ( | Tblastn & | tb | ) |
making a real copy of the matches member from the Tblastn object. The only change to Tblastn is sorting the matches vector based on targetRange.
References end2match, Tblastn::findSections(), Tblastn::getMatches(), sections, start2match, and xpoints.
| M8MatchEX * Linkmatch::bestModel | ( | ForwardIterator | first, | |
| ForwardIterator | last, | |||
| const Match & | box | |||
| ) | [inline] |
more generat version, allows the same code to be applied to both the + and - strand of DNA ForwardIterator is for iterating the xpoints in forward and reverse direction.
box is the section that contain all the matches in a particular section.
Return the pointer to the last element of the best chain. The Last pointer which can be used to construct the best alighment.
References best, cleanUpBest(), Match::contain(), end2match, I, show_end2match(), show_start2match(), and start2match.
Referenced by bestModel(), and storeBestModels().
produce the best chain from the matches contained inside sec Return the pointer to the end of the chain.
References bestModel(), Match::targetBegin(), Match::targetEnd(), Match::targetOnPlus(), and xpoints.
| void Linkmatch::bestModel | ( | vector< Boxchain * > & | topmodels | ) |
put all the top 80% models into the topmodels vector If topmodels is not empty, it clears the vector. For the pointer version, we need to deallocate memory.
References bestModel(), M8MatchEX::getMaxScore(), removeChain(), and sections.
| void Linkmatch::showBest | ( | ostream & | ous | ) | const |
display the final best set content this contains the final result
References best, and M8MatchEX::previous().
| void Linkmatch::show_best | ( | ostream & | ous | ) | const |
| void Linkmatch::show_end2match | ( | ostream & | ous | ) | const |
| void Linkmatch::show_start2match | ( | ostream & | ous | ) | const |
| void Linkmatch::show_sections | ( | ostream & | ous | ) | const |
find sections on the target (genomic) where all matches are in the same direction as regards to targets Thse section may overlap. Requirement: The tblastn must have been sorted by target. This class does not have enough information to do this job well. The data structure is also not easy for deletion. remove M8MatchEX* from start2match and end2match, then update the set<int> xpoint and reduced the target range of the box to reflect the new boundary of the section
References Match::contain(), end2match, I, max, min, M8MatchEX::previous(), Match::queryBegin(), Match::queryEnd(), Match::set(), Match::setNull(), show_best(), show_sections(), show_start2match(), start2match, Match::targetBegin(), Match::targetEnd(), Match::targetOnPlus(), and xpoints.
Referenced by bestModel().
| void Linkmatch::cleanUpBest | ( | bestiterator | bi | ) | [private] |
bi is the iterator pointing to the element just inserted. This element will be used for comparision, any element after this one that has a smaller score will be removed
References best.
Referenced by bestModel().
set<int> Linkmatch::xpoints [private] |
this should contain the matches sorted by target We don't need this one if we store pointers.
Referenced by bestModel(), Linkmatch(), and removeChain().
multimap<int, M8MatchEX*> Linkmatch::start2match [private] |
Referenced by bestModel(), Linkmatch(), removeChain(), show_start2match(), and ~Linkmatch().
multimap<int, M8MatchEX*> Linkmatch::end2match [private] |
Referenced by bestModel(), Linkmatch(), removeChain(), and show_end2match().
multiset<M8MatchEX*, ltMatchQueryBeginPtr> Linkmatch::best [private] |
although this set may contain elements starting at the same b.y, their scores must be different Order by queryBegin, then by maxScore
Referenced by bestModel(), cleanUpBest(), show_best(), and showBest().
vector<Match> Linkmatch::sections [private] |
Referenced by bestModel(), Linkmatch(), and show_sections().
1.5.6