creating genebank file using own record entries
0
0
Entering edit mode
19 months ago
APJ ▴ 30

Hello, I would like to create the new genebank file using the results obtained from my analysis. I could write to a genebank file, but my annotations are not printed to the output genebank file (as you can see in the output file: FEATURES Location/Qualifiers- are empty). I read the biopython documents. They have described how to enter the SeqRecord, but how to add additional features is not defined, or maybe, my eyes couldn't find the relevant ones. Any suggestions on this, please?


    a_info = SeqRecord(seq[1]['seq'],
                       id=a1_rec.id, name='G1',
                       description=a1_rec.description)

    a_info.annotations['Protein_Domain']= str(['P1','P2'])
    a_info.annotations["Coordinates"] = desc +' '+str(region)

    a_info.annotations["Transcripts"] = tran_lst 

    a_info.annotations['protein_domains'] = domain_dict

    SeqIO.write(a_info, 'test.gb','genbank')

Output file:

```

LOCUS       G1                    7780 bp    DNA              UNK 01-JAN-1980
DEFINITION  Homo sapiens chromosome 14, GRCh38.p13 Primary Assembly.
ACCESSION   NC_00022
VERSION     NC_00022.1
KEYWORDS    .
SOURCE      .
  ORGANISM  .
            .
FEATURES             Location/Qualifiers
ORIGIN
        1 tcaggccgtg ccgctggccg agtaggagaa ctgggggaag tggggcctgc gctcgctgtc
       61 cacacactcc atgctgtcat cttggtcagg tggtgtgatg gtgatcatct gggccgtgaa
      121 ctcctcatca aaatacctgg tgtcagtctc cgacgtgacc tggggcttga agggtgggct
      181 gagcttcttc tcgtacacgt gctgccacac gataccggca aagaagcgat gctgcatgat
      241 ctccttggcg tcctcggagc ccccgccaag cctctgcttg gggtccttct tgagcagccc
      301 tgaaagcaag gacttggcct cgggaccaag cgtgcgcggg aagcggatct cctccatgag
      361 gatgagctca aaaagcttct catggtcctg gttgtagaag ggcaggcgac cgcacatcat
      421 ctcgtacatg accacgccca gcccccacca gtccactgca cggccgtagt cattgtcctc
      481 cagcacctcg ggggccaggt actcaggtgt gccgcaaaag gtcttcatgg tggcaccgtc
      541 cttgatcccc tcctt
```
SeqIO genebank Genebank biopython • 303 views
ADD COMMENT
0
Entering edit mode

You need to show us more of the code. We don't know where any of the data is coming from, what form it's in etc.

ADD REPLY

Login before adding your answer.

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