[Biojava-l] aligning sequences with ambiguous bases

Wim De Smet Wim.DeSmet at UGent.be
Tue Mar 29 09:59:18 UTC 2011


Hi Mark

Thanks! I guess I should have pressed my Get Mail button before sending 
my second message. Good to know I chose the "correct" solution.

cheers
Wim

On 29-03-11 10:06, Mark Chapman wrote:
> Hi Wim,
>
> The use of ambiguous nucleotides requires you to use the
> AmbiguityDNACompoundSet when you create your DNASequence, which means any:
>
> new DNASequence(<yourString>)
>
> changes to:
>
> new DNASequence(<yourString>, AmbiguityDNACompoundSet.getDNACompoundSet())
>
> I hope that helps,
> Mark
>
>
> On 3/28/2011 9:46 AM, Wim De Smet wrote:
>> Hi
>>
>> (sorry if you get 2 copies, I sent this to -request by mistake)
>>
>> Apologies if this has come up before, a quick search didn't turn
>> anything up.
>>
>> I'm attempting to do a pairwise alignment between two DNA sequences using
>> biojava 3. When I try to construct a DNASequence from a string that
>> contains an
>> ambiguous base though (in this case 'y'), I get the following stacktrace.
>>
>> Exception in thread "main"
>> org.biojava3.core.exceptions.CompoundNotFoundError:
>> Compound not found for: Cannot find compound for: y
>> at
>> org.biojava3.core.sequence.storage.ArrayListSequenceReader.setContents(ArrayListSequenceReader.java:196)
>>
>>
>> at
>> org.biojava3.core.sequence.template.AbstractSequence.<init>(AbstractSequence.java:88)
>>
>>
>> at org.biojava3.core.sequence.DNASequence.<init>(DNASequence.java:64)
>>
>> Should I attempt to mask them somehow? What's the best way to deal
>> with these?
>>
>> cheers
>> Wim
> _______________________________________________
> Biojava-l mailing list - Biojava-l at lists.open-bio.org
> http://lists.open-bio.org/mailman/listinfo/biojava-l


-- 
Wim De Smet
http://www.straininfo.net/



More information about the Biojava-l mailing list