Skip to content

o.b.n.core.sequence.CDSSequence doesn't reverse-complement correctly #1016

@richarda23

Description

@richarda23

Given a transcript sequence derived from a GeneSequence defined on reverse strand of a chromosomal sequence, the method getCodingSequence doesn't return the reverse complement, but just the reverse.

This seems to be due to the complement being made twice:

String sequence = this.getSequenceAsString(getBioBegin(), getBioEnd(), getStrand()); 

in CDSSequence# getCodingSequence()

generates the reverse complement, but subsequent code makes a complementary sequence again, so the end result is simply a reversed sequence.

A simple fix might be just to remove this second complementation, but possibly it might be needed in some circumstances.

The bug is exposed by test TranscriptSequenceTest#getCDNASeqNegativeStrand()

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugBugs and bugfixes

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions