-1

これが私のコードです:

from Bio.Blast import NCBIWWW          
result = NCBIWWW.qblast("blastn","nt",r"C:\Users\video\Documents\sars.fasta")  
save_file = open("blast4.xml", "w")
save_file.write(result.read())
save_file.close()
result.close()
result = open("blast4.xml")
from Bio.Blast import NCBIXML
records = NCBIXML.parse(result)
blast_record = records.__next__()
# Up till here there are no problems 

for alignment in blast_record.alignments:
    for hsp in alignment.hsps:
        if hsp.expect <0.01:
            print('****Alignment****') 
            print('sequence:', alignment.title) 
            print('length:', alignment.length) 
            print('score:', hsp.score) 
            print('gaps:', hsp.gaps) 
            print('e value:', hsp.expect) 
            print(hsp.query[0.90] + '...') 
            print(hsp.match[0.90] + '...') 
            print(hsp.sbjct[0.90] + '...')

コードは実行されているようですが、何も出力されません! テーブルも何もありません。コードは実行されるだけで何もありません。どうした?

4

1 に答える 1