def fasta_files_equal(seq_file1, seq_file2):
"""Check equality of a FASTA file to another FASTA file
Args:
seq_file1: Path to a FASTA file
seq_file2: Path to another FASTA file
Returns:
bool: If the sequences are the same
"""
# Load already set representative sequence
seq1 = SeqIO.read(open(seq_file1), 'fasta')
# Load kegg sequence
seq2 = SeqIO.read(open(seq_file2), 'fasta')
# Test equality
if str(seq1.seq) == str(seq2.seq):
return True
else:
return False
评论列表
文章目录