from Bio import SeqIO
for record in SeqIO.parse("sequence.fasta", "fasta"):
print(record.id)
print(record.seq)
from Bio import Align
aligner = Align.PairwiseAligner()
alignments = aligner.align("ACGT", "AGT")
for alignment in alignments:
print(alignment)
print(alignment.score)
from Bio.Seq import Seq
seq = Seq("ATGCGTAA")
protein = seq.translate()
print(protein)
from Bio.Blast import NCBIWWW
result_handle = NCBIWWW.qblast("blastn", "nt", "ATCG")
print(result_handle.read())
from Bio import SeqIO
for record in SeqIO.parse("genome.gb", "genbank"):
for feature in record.features:
if feature.type == "gene":
print(feature)