This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Target sequence from exonerate output

How to retrieve target sequence from exonerate output?

from Bio import SearchIO
qresult = SearchIO.read('my_input', 'exonerate-text')
hit=qresult.hits
print hit[0].hsps[0]

and i get a list of coordinates

           #            Span             Query range               Hit range
         ---  --------------  ----------------------  ----------------------
           0             208                 [0:208]     [12722276:12722484]
           1            1512              [208:1720]     [12722558:12724070]
           2             138             [1720:1858]     [12724205:12724343]
           3             147             [1858:2005]     [12724471:12724618]
           4              85             [2005:2090]     [12725711:12725796]
           5             820             [2090:2910]     [12725858:12726678]
           6             371             [2910:3281]     [12726745:12727116]
           7             221             [3281:3502]     [12729184:12729405]
           8             218             [3502:3720]     [12737958:12738176]
           9             507             [3720:4227]     [12738240:12738747]
          10             382             [4227:4609]     [12738806:12739188]
          11             828             [4609:5437]     [12743979:12744807]
  

But i can't find an option to retrieve the whole target sequence, is there a way to do this?

biopython exonerate

0 answers

No answers yet.

Log in to answer this question.