本文整理汇总了Python中Bio.SearchIO._index.SearchIndexer类的典型用法代码示例。如果您正苦于以下问题:Python SearchIndexer类的具体用法?Python SearchIndexer怎么用?Python SearchIndexer使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了SearchIndexer类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: __init__
def __init__(self, filename, comments=False, fields=_DEFAULT_FIELDS):
SearchIndexer.__init__(self, filename, comments=comments, fields=fields)
# if the file doesn't have comments,
# get index of column used as the key (qseqid / qacc / qaccver)
if not self._kwargs['comments']:
if 'qseqid' in fields:
self._key_idx = fields.index('qseqid')
elif 'qacc' in fields:
self._key_idx = fields.index('qacc')
elif 'qaccver' in fields:
self._key_idx = fields.index('qaccver')
else:
raise ValueError("Custom fields is missing an ID column. "
"One of these must be present: 'qseqid', 'qacc', or 'qaccver'.")
示例2: __init__
def __init__(self, filename):
SearchIndexer.__init__(self, filename)
# TODO: better way to do this?
iter_obj = self._parser(self._handle)
self._meta, self._fallback = iter_obj._meta, iter_obj._fallback
示例3: __init__
def __init__(self, filename, pslx=False):
SearchIndexer.__init__(self, filename, pslx=pslx)
示例4: __init__
def __init__(self, filename):
SearchIndexer.__init__(self, filename)
self._handle = UndoHandle(self._handle)
示例5: __init__
def __init__(self, filename, **kwargs):
"""Initialize the class."""
SearchIndexer.__init__(self, filename)
# TODO: better way to do this?
iter_obj = self._parser(self._handle, **kwargs)
self._meta, self._fallback = iter_obj._meta, iter_obj._fallback
示例6: __init__
def __init__(self, filename, pslx=False):
"""Initialize the class."""
SearchIndexer.__init__(self, filename, pslx=pslx)
示例7: __init__
def __init__(self, filename):
"""Initialize the class."""
SearchIndexer.__init__(self, filename)
self._handle = UndoHandle(self._handle)