Hi Beifang, right now, we do not plan to implement traceback for extendSeed, though we might in the future. If you do not fear to modify code, the most efficient way to get the *number* of matching positions is without traceback at all, i.e. also without global alignment: While extending the seed, parts of a DP matrix is filled with scores. In addition to that score, you could store the number of matching positions for each matrix entry. In the code this would mean to replace occurrences of TScoreValue by Pair<TScoreValue, unsigned> (for the antidiagonals and tmp variables), and to increase the unsigned value if the max for one matrix entry is a match. The current seeds-module uses end positions that are not consistent with the rest of SeqAn. For the rest of SeqAn, the position behind the last position is the end position, i.e. end - start = length. Also, diagonals are counted from left/bottom to right/top and not the other way around. Unfortunately, the seeds-module does it differently. That is why you have to take the negative of the diagonals. This is also one of the reasons why the seeds2-module is already there (fixing these inconsistencies). As soon as all functionality is implemented and tested in the seeds2-module we will replace the seeds-module by it. The implementation of seed extension in the seeds2-module is already stable. -Birte From: Beifang Niu [mailto:neilniu.cn@gmail.com] Hi Birte, Do you have plan to add traceback implement in extendSeed function to get match numbers or seed identity? maybe, it will consume less CPU time than the process extendSeed+globalAlignment. I am confusing that why the minus dignonals "-leftDiagonal(seed) - 2, -rightDiagonal(seed) + 2" were used in tutorial example. Can I use the same style in my real seed extension? I used the simple score "Score<TScore, Simple> scoreMatrix(1, -2, -1, -6);" and I think this kind of score is not helpful to get match numbers based on the return score from extendSeed. thanks, Beifang. On Thu, Oct 27, 2011 at 3:41 PM, Kehr, Birte <Birte.Kehr@fu-berlin.de> wrote: Yes, in the case of gapped X-drop extension you have to do globalAlignment. The function extendSeed does not do the traceback and does not determine the number of matching positions.
Sent: Thursday, October 27, 2011 11:15 PM
On Thu, Oct 27, 2011 at 2:08 PM, Kehr, Birte <Birte.Kehr@fu-berlin.de<mailto:Birte.Kehr@fu-berlin.de>> wrote: From: Beifang Niu [neilniu.cn@gmail.com<mailto:neilniu.cn@gmail.com>] Sent: Thursday, October 27, 2011 9:19 PM On Tue, Oct 25, 2011 at 3:00 AM, <seqan-dev-request@lists.fu-berlin.de<mailto:seqan-dev-request@lists.fu-berlin.de><mailto:seqan-dev-request@lists.fu-berlin.de<mailto:seqan-dev-request@lists.fu-berlin.de>>> wrote: seqan-dev@lists.fu-berlin.de<mailto:seqan-dev@lists.fu-berlin.de><mailto:seqan-dev@lists.fu-berlin.de<mailto:seqan-dev@lists.fu-berlin.de>>
seqan-dev-request@lists.fu-berlin.de<mailto:seqan-dev-request@lists.fu-berlin.de><mailto:seqan-dev-request@lists.fu-berlin.de<mailto:seqan-dev-request@lists.fu-berlin.de>>
seqan-dev-owner@lists.fu-berlin.de<mailto:seqan-dev-owner@lists.fu-berlin.de><mailto:seqan-dev-owner@lists.fu-berlin.de<mailto:seqan-dev-owner@lists.fu-berlin.de>>
From: Beifang Niu <neilniu.cn@gmail.com<mailto:neilniu.cn@gmail.com><mailto:neilniu.cn@gmail.com<mailto:neilniu.cn@gmail.com>>> Subject: [Seqan-dev] about extendSeed of Seqan To: seqan-dev@lists.fu-berlin.de<mailto:seqan-dev@lists.fu-berlin.de><mailto:seqan-dev@lists.fu-berlin.de<mailto:seqan-dev@lists.fu-berlin.de>> Content-Type: text/plain; charset="iso-8859-1" From: "Kehr, Birte" <Birte.Kehr@fu-berlin.de<mailto:Birte.Kehr@fu-berlin.de><mailto:Birte.Kehr@fu-berlin.de<mailto:Birte.Kehr@fu-berlin.de>>> Subject: Re: [Seqan-dev] about extendSeed of Seqan To: SeqAn Development <seqan-dev@lists.fu-berlin.de<mailto:seqan-dev@lists.fu-berlin.de><mailto:seqan-dev@lists.fu-berlin.de<mailto:seqan-dev@lists.fu-berlin.de>>> Content-Type: text/plain; charset="us-ascii" From: Beifang Niu [mailto:neilniu.cn@gmail.com<mailto:neilniu.cn@gmail.com><mailto:neilniu.cn@gmail.com<mailto:neilniu.cn@gmail.com>>] Sent: Montag, 24. Oktober 2011 14:51 To: seqan-dev@lists.fu-berlin.de<mailto:seqan-dev@lists.fu-berlin.de><mailto:seqan-dev@lists.fu-berlin.de<mailto:seqan-dev@lists.fu-berlin.de>> Subject: [Seqan-dev] about extendSeed of Seqan seqan-dev@lists.fu-berlin.de<mailto:seqan-dev@lists.fu-berlin.de><mailto:seqan-dev@lists.fu-berlin.de<mailto:seqan-dev@lists.fu-berlin.de>> https://lists.fu-berlin.de/listinfo/seqan-dev |