Label Names By Genomediagram, Biopython
1
3
Entering edit mode
13.2 years ago
Laura ▴ 40

I am using GenomeDiagram to draw linear genome fragments (using genbank SeqRecords). I found that, by default, the name of the labels correspond to 'locus_tag' (when I select to show the labels for 'CDS' features), and I would like to get the 'product' instead. Is there a way to select 'product' for the label names?

genome visualization biopython python • 2.5k views
ADD COMMENT
5
Entering edit mode
13.2 years ago
Peter 6.0k

This is controlled by the name_qualifiers attribute of the GenomeDiagram Feature object. By default it looks at these tags:

name_qualifiers = ['gene', 'label', 'name', 'locus_tag', 'product']

So one answer would be to override that setting (on every Feature object). Alternatively, you could edit the qualifiers of the SeqFeature before calling GenomeDiagram to copy the desired annotation into a new label or name qualifier which would then take precedence over the locus_tag.

ADD COMMENT

Login before adding your answer.

Traffic: 1633 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