From b47d896d889ffa3ee22f1745b553bbdc917ec9c5 Mon Sep 17 00:00:00 2001 From: free hacker <freeh4cker@gmail.com> Date: Thu, 18 Feb 2016 00:25:32 +0100 Subject: [PATCH] fix space to be pep8 compliant --- source/_static/code/multiple_fasta_reader.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/source/_static/code/multiple_fasta_reader.py b/source/_static/code/multiple_fasta_reader.py index 1d94a76..d6a367e 100644 --- a/source/_static/code/multiple_fasta_reader.py +++ b/source/_static/code/multiple_fasta_reader.py @@ -1,6 +1,6 @@ from collections import namedtuple -Sequence = namedtuple("Sequence", "id comment sequence") +Sequence = namedtuple("Sequence", "id comment sequence") def fasta_reader(fasta_path): """ @@ -19,19 +19,18 @@ def fasta_reader(fasta_path): # a new sequence begin if id_ != '': # a sequence was already parsed so add it to the list - sequences.append(Sequence(id_ , comment, sequence)) + sequences.append(Sequence(id_, comment, sequence)) sequence = '' header = line.split() id_ = header[0] comment = ' '.join(header[1:]) else: sequence += line.strip() - sequences.append(Sequence(id_ , comment, sequence)) + sequences.append(Sequence(id_, comment, sequence)) return sequences # The problem with this implementation is that we have to load all # sequences in memory before to start to work with # it is better to return sequence one by one -# and treat them as they are loaded. - \ No newline at end of file +# and treat them as they are loaded. \ No newline at end of file -- GitLab