Options stuff... ;-)
This commit is contained in:
@ -21,9 +21,15 @@ default_config = { 'software' : "The OBITools",
|
|||||||
'log' : False,
|
'log' : False,
|
||||||
'loglevel' : 'INFO',
|
'loglevel' : 'INFO',
|
||||||
'progress' : True,
|
'progress' : True,
|
||||||
|
'inputURI' : None,
|
||||||
'defaultdms' : None,
|
'defaultdms' : None,
|
||||||
'inputview' : None,
|
'inputview' : None,
|
||||||
'outputview' : None
|
'outputview' : None,
|
||||||
|
'skip' : 0,
|
||||||
|
'only' : None,
|
||||||
|
'skiperror' : True,
|
||||||
|
'qualityformat' : 'sanger',
|
||||||
|
'moltype' : 'nuc'
|
||||||
}
|
}
|
||||||
|
|
||||||
root_config_name='obi'
|
root_config_name='obi'
|
||||||
|
@ -1,17 +1,23 @@
|
|||||||
def addInputOption(optionManager):
|
def addInputOption(optionManager):
|
||||||
|
|
||||||
|
optionManager.add_argument(
|
||||||
|
dest='obi:inputURI',
|
||||||
|
metavar='index',
|
||||||
|
help='index root filename (produced by the oa index command)')
|
||||||
|
|
||||||
|
|
||||||
group = optionManager.add_argument_group("Restriction to a sub-part options",
|
group = optionManager.add_argument_group("Restriction to a sub-part options",
|
||||||
"Allow to limit analysis to a sub-part of the data file")
|
"Allow to limit analysis to a sub-part of the data file")
|
||||||
|
|
||||||
group.add_argument('--skip',
|
group.add_argument('--skip',
|
||||||
action="store", dest="skip",
|
action="store", dest="obi:skip",
|
||||||
metavar='<N>',
|
metavar='<N>',
|
||||||
default=None,
|
default=None,
|
||||||
type='int',
|
type='int',
|
||||||
help="skip the N first sequences")
|
help="skip the N first sequences")
|
||||||
|
|
||||||
group.add_argument('--only',
|
group.add_argument('--only',
|
||||||
action="store", dest="only",
|
action="store", dest="obi:only",
|
||||||
metavar='<N>',
|
metavar='<N>',
|
||||||
default=None,
|
default=None,
|
||||||
type='int',
|
type='int',
|
||||||
@ -21,30 +27,30 @@ def addInputOption(optionManager):
|
|||||||
"If not specified, a test is done to determine the file format")
|
"If not specified, a test is done to determine the file format")
|
||||||
|
|
||||||
group.add_argument('--skip-on-error',
|
group.add_argument('--skip-on-error',
|
||||||
action="store_true", dest="skiperror",
|
action="store_true", dest="obi:skiperror",
|
||||||
default=False,
|
default=False,
|
||||||
help="Skip sequence entries with parse error")
|
help="Skip sequence entries with parse error")
|
||||||
|
|
||||||
group.add_argument('--quality-sanger',
|
group.add_argument('--quality-sanger',
|
||||||
action="store_const", dest="seqinformat",
|
action="store_const", dest="obi:qualityformat",
|
||||||
default=None,
|
default=None,
|
||||||
const='sanger',
|
const='sanger',
|
||||||
help="Input file is in sanger fastq nucleic format (standard fastq)")
|
help="Input file is in sanger fastq nucleic format (standard fastq)")
|
||||||
|
|
||||||
group.add_argument('--quality-solexa',
|
group.add_argument('--quality-solexa',
|
||||||
action="store_const", dest="seqinformat",
|
action="store_const", dest="obi:qualityformat",
|
||||||
default=None,
|
default=None,
|
||||||
const='solexa',
|
const='solexa',
|
||||||
help="Input file is in fastq nucleic format produced by solexa sequencer")
|
help="Input file is in fastq nucleic format produced by solexa sequencer")
|
||||||
|
|
||||||
group.add_argument('--nuc',
|
group.add_argument('--nuc',
|
||||||
action="store_const", dest="moltype",
|
action="store_const", dest="obi:moltype",
|
||||||
default=None,
|
default=None,
|
||||||
const='nuc',
|
const='nuc',
|
||||||
help="Input file contains nucleic sequences")
|
help="Input file contains nucleic sequences")
|
||||||
|
|
||||||
group.add_argument('--prot',
|
group.add_argument('--prot',
|
||||||
action="store_const", dest="moltype",
|
action="store_const", dest="obi:moltype",
|
||||||
default=None,
|
default=None,
|
||||||
const='pep',
|
const='pep',
|
||||||
help="Input file contains protein sequences")
|
help="Input file contains protein sequences")
|
||||||
|
@ -12,7 +12,8 @@ import time
|
|||||||
__title__="Grep view lines that match the given predicates"
|
__title__="Grep view lines that match the given predicates"
|
||||||
|
|
||||||
default_config = { 'inputview' : None,
|
default_config = { 'inputview' : None,
|
||||||
'outputview' : None
|
'outputview' : None,
|
||||||
|
'predicates' : []
|
||||||
}
|
}
|
||||||
|
|
||||||
def addOptions(parser):
|
def addOptions(parser):
|
||||||
|
Reference in New Issue
Block a user