From 8eccd8703511a3abde58f3d0b254dc42fd310f89 Mon Sep 17 00:00:00 2001 From: Eric Coissac Date: Fri, 29 Jun 2007 07:14:53 +0000 Subject: [PATCH] git-svn-id: https://www.grenoble.prabi.fr/svn/LECASofts/ecoPCR/branches/refactoring@85 60f365c0-8329-0410-b2a4-ec073aeeaa1d --- tools/ecoPCRFormat.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/tools/ecoPCRFormat.py b/tools/ecoPCRFormat.py index b28cda5..3acb26c 100755 --- a/tools/ecoPCRFormat.py +++ b/tools/ecoPCRFormat.py @@ -68,8 +68,7 @@ def endLessIterator(endedlist): yield x while(1): yield endedlist[-1] - - + class ColumnFile(object): def __init__(self,stream,sep=None,strip=True,types=None): @@ -135,7 +134,7 @@ def bsearchTaxon(taxonomy,taxid): else: return None - + def readNodeTable(file): @@ -149,7 +148,6 @@ def readNodeTable(file): bool,bool,bool,str)) print >>sys.stderr,"Reading taxonomy dump file..." taxonomy=[[n[0],n[2],n[1]] for n in nodes] - print >>sys.stderr,"List all taxonomy rank..." ranks =list(set(x[1] for x in taxonomy)) ranks.sort() @@ -292,6 +290,7 @@ def emblEntryParser(entry): Tx = None return {'id':Id,'taxid':Tx,'definition':De,'sequence':Sq} + ###################### def parseFasta(seq): @@ -315,7 +314,6 @@ def fastaEntryParser(entry): return {'id':id,'taxid':Tx,'definition':definition,'sequence':seq} - def sequenceIteratorFactory(entryParser,entryIterator): def sequenceIterator(file): for entry in entryIterator(file):