A new version of ngsfilger without a bug about error count between primers and sequence
This commit is contained in:
@ -356,6 +356,7 @@ def annotate(sequence,options):
|
||||
sequence['tail_quality']=q
|
||||
|
||||
primers = options.primers
|
||||
if options.debug:
|
||||
print >>sys.stderr,"directmatch"
|
||||
directmatch = [(p,p(sequence)) for p in primers]
|
||||
|
||||
@ -363,6 +364,7 @@ def annotate(sequence,options):
|
||||
directmatch.sort(cmp=sortMatch)
|
||||
directmatch=directmatch[0] if directmatch[0][1] is not None else None
|
||||
|
||||
if options.debug:
|
||||
print >>sys.stderr,">>>>",directmatch
|
||||
if directmatch is None:
|
||||
sequence['error']='No primer match'
|
||||
@ -389,11 +391,13 @@ def annotate(sequence,options):
|
||||
del sequence['cut']
|
||||
|
||||
primers = options.primers[directmatch[0]]
|
||||
if options.debug:
|
||||
print >>sys.stderr,"reverse match"
|
||||
reversematch = [(p,p(sequence)) for p in primers if p is not None]
|
||||
reversematch.sort(cmp=sortMatch)
|
||||
reversematch = reversematch[0] if reversematch[0][1] is not None else None
|
||||
|
||||
if options.debug:
|
||||
print >>sys.stderr,"<<<<",reversematch
|
||||
if reversematch is None and None not in primers:
|
||||
if directmatch[0].direct:
|
||||
|
Reference in New Issue
Block a user