Biopython have SeqIO write a circular annotation to Genbank header
1
0
Entering edit mode
4.1 years ago
Harijay ▴ 60

While writing a new sequence to a genbank file . I am using code like

_seqrecord = SeqRecord.SeqRecord(Seq.Seq(seq,generic_dna),name=name, id=seqID, description=self.description)
 SeqIO.write(_seqrecord,handle=outfile ,format="genbank")

Is there a way to set the topology of the sequence to circular ?

I could see something in the source code about setting topology in a FeatureConsumer, but am still confused as to how I can set the topology or residue type to circular DNA during output of a seqrecord.

biopython • 1.4k views
ADD COMMENT
1
Entering edit mode
4.1 years ago
Harijay ▴ 60

I figured it out immediately after posting.

_seqrecord.annotations["topology"]="circular"

Sets the topology to circular.

ADD COMMENT

Login before adding your answer.

Traffic: 2352 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6