Commit 18d87aa1 by Eric Coissac

Add a small work around patch for the --skip and --only options in

illuminapairedend
parent 1c91c27e
......@@ -48,13 +48,14 @@ from obitools.options import getOptionManager, allEntryIterator
from obitools.align import QSolexaReverseAssemble
from obitools.align import QSolexaRightReverseAssemble
from obitools.tools._solexapairend import buildConsensus
from obitools.format.options import addInputFormatOption,addOutputFormatOption,\
from obitools.format.options import addOutputFormatOption,\
sequenceWriterGenerator
from itertools import chain
import cPickle
import math
from obitools.fastq._fastq import fastqIterator
from obitools.fastq._fastq import fastqIterator # @UnresolvedImport
def addSolexaPairEndOptions(optionManager):
optionManager.add_option('-r','--reverse-reads',
......@@ -90,14 +91,6 @@ def addSolexaPairEndOptions(optionManager):
const='illumina',
help="input file is in fastq nucleic format produced by old solexa sequencer")
# optionManager.add_option('--proba',
# action="store", dest="proba",
# metavar="<FILENAME>",
# type="str",
# default=None,
# help="null ditribution data file")
optionManager.add_option('--score-min',
action="store", dest="smin",
metavar="#.###",
......@@ -105,13 +98,6 @@ def addSolexaPairEndOptions(optionManager):
default=None,
help="minimum score for keeping aligment")
# optionManager.add_option('--pvalue',
# action="store", dest="pvalue",
# metavar="#.###",
# type="float",
# default=None,
# help="maximum pvalue for keeping aligment")
def cutDirectReverse(entries):
......@@ -222,6 +208,8 @@ if __name__ == '__main__':
#WARNING TO REMOVE : DIRTY PATCH !
options.proba = None
options.skip = None
options.only = None
options.sminL = None
......
......@@ -313,11 +313,11 @@ def autoEntriesIterator(options):
if options.skiperror:
reader = skipOnErrorIterator(reader)
if options.skip is not None:
if hasattr(options, 'skip') and options.skip is not None:
print >>sys.stderr,"Skipping %d sequences" % options.skip
reader = skipfirst(reader,options.skip)
if options.only is not None:
if hasattr(options, 'only') and options.only is not None:
print >>sys.stderr,"Analysing only %d sequences" % options.only
reader = only(reader,options.only)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment