Hi, is the following one possibility of what you want your alignment
to look like?
----CDFH--------
|
CAAAADAAAAFAAAAH
Then you should try passing AlignConfig<false, true, true,
false>() as an additional parameter to the globalAlignment
function. This will not add gap penalties for leading and
trailing gaps in the first sequence.
http://docs.seqan.de/seqan/dev3/?p=AlignConfig
http://docs.seqan.de/seqan/dev3/?p=globalAlignment
Birte
Am 23.01.2014 08:19, schrieb Karrde:
Sorry if you got this
twice, I just realized I accidentally hit reply instead of
reply-all.
First off, thanks for the
response.
I tried your idea but I'm
not getting the correct results, I still see several gaps in
the alignment. I also tried setting the gap-extend to a high
cost while leaving gap-open at 0, but this doesn't actually
seem to do anything to the score returned.
Here's the code I used:
TSequence seq1 = "CDFH";
TSequence seq2 =
"CAAAADAAAAFAAAAH";
TAlign align;
resize(rows(align), 2);
assignSource(row(align,0),seq1);
assignSource(row(align,1),seq2);
//trying to set the gap
penalty extra high
seqan::Score<int,
seqan::ScoreMatrix<seqan::AminoAcid,
seqan::Blosum62_>> scoreRoutine(-100,0);
Output from
scoreRoutine(-100,0)
Score: 27
0 . : .
C----D----F----H
| | | |
CAAAADAAAAFAAAAH
Output from
scoreRoutine(-100,-100)
Score: -1173
0 . : .
C----D----F----H
| | | |
CAAAADAAAAFAAAAH
Hi, simply use very high gap costs in the constructor.
*m
Hello,
I want to perform an alignment such that there are no gaps
allowed using the Blosum62 mutation matrix. In practice, one
of my sequences will be much smaller than the other. I want it
to align as close as possible to the longer sequence without
allowing any gaps. Is there a flag or something I can set to
disallow any gaps or set the maximum number of gaps allowed?
I'm new to SeQan, but here's what I have so far (test
data):
typedef seqan::String<char> TSequence;
typedef seqan::Align<TSequence,seqan::ArrayGaps> TAlign;
TSequence seq1 = "CDFGAAAHC";
TSequence seq2 = "CDEFGAHC";
TAlign align;
resize(rows(align), 2);
assignSource(row(align,0),seq1);
assignSource(row(align,1),seq2);
double score = globalAlignment(align, seqan::Score<int,
seqan::ScoreMatrix<seqan::AminoAcid,
seqan::Blosum62_>>());
std::cout << "Score: " << score <<
::std::endl;
std::cout << align << ::std::endl;
Thanks for any and all help!
Hi, simply use very high gap costs in the constructor.
*m
Hello,
I want to perform an alignment such that there are
no gaps allowed using the Blosum62 mutation matrix. In
practice, one of my sequences will be much smaller
than the other. I want it to align as close as
possible to the longer sequence without allowing any
gaps. Is there a flag or something I can set to
disallow any gaps or set the maximum number of gaps
allowed?
I'm new to SeQan, but here's what I have so far
(test data):
typedef seqan::String<char> TSequence;
typedef
seqan::Align<TSequence,seqan::ArrayGaps>
TAlign;
TSequence seq1 = "CDFGAAAHC";
TSequence seq2 = "CDEFGAHC";
TAlign align;
resize(rows(align), 2);
assignSource(row(align,0),seq1);
assignSource(row(align,1),seq2);
double score = globalAlignment(align,
seqan::Score<int,
seqan::ScoreMatrix<seqan::AminoAcid,
seqan::Blosum62_>>());
std::cout << "Score: " << score
<< ::std::endl;
std::cout << align << ::std::endl;
Thanks for any and all help!
_______________________________________________
seqan-dev mailing list
seqan-dev@lists.fu-berlin.de
https://lists.fu-berlin.de/listinfo/seqan-dev
|