Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(30)  |  Call(22)  |  Derive(0)  |  Import(8)

src/b/i/biopython-1.63/Bio/SearchIO/_model/hit.py   biopython(Download)
from Bio._py3k import filter
 
from Bio._utils import getattr_str, trim_str
from Bio.SearchIO._utils import allitems, optionalcascade
 
        qid_line = 'Query: %s' % self.query_id
        if self.query_description:
            qid_line += trim_str('\n       %s' %
                    self.query_description, 80, '...')
        lines.append(qid_line)
            hid_line += ' (%i)' % self.seq_len
        if self.description:
            hid_line += trim_str('\n       %s' % self.description,
                    80, '...')
        lines.append(hid_line)
                query_range = '[%s:%s]' % (query_start, query_end)
                # max column length is 18
                query_range = trim_str(query_range, 15, '~]')
                # hit region
                hit_start = getattr_str(hsp, 'hit_start')
                hit_end = getattr_str(hsp, 'hit_end')
                hit_range = '[%s:%s]' % (hit_start, hit_end)
                hit_range = trim_str(hit_range, 21, '~]')

src/b/i/biopython-HEAD/Bio/SearchIO/_model/hit.py   biopython(Download)
from Bio._py3k import filter
 
from Bio._utils import getattr_str, trim_str
from Bio.SearchIO._utils import allitems, optionalcascade
 
        qid_line = 'Query: %s' % self.query_id
        if self.query_description:
            qid_line += trim_str('\n       %s' %
                    self.query_description, 80, '...')
        lines.append(qid_line)
            hid_line += ' (%i)' % self.seq_len
        if self.description:
            hid_line += trim_str('\n       %s' % self.description,
                    80, '...')
        lines.append(hid_line)
                query_range = '[%s:%s]' % (query_start, query_end)
                # max column length is 18
                query_range = trim_str(query_range, 15, '~]')
                # hit region
                hit_start = getattr_str(hsp, 'hit_start')
                hit_end = getattr_str(hsp, 'hit_end')
                hit_range = '[%s:%s]' % (hit_start, hit_end)
                hit_range = trim_str(hit_range, 21, '~]')

src/b/i/biopython-1.63/Bio/SearchIO/_model/hsp.py   biopython(Download)
from Bio.SeqRecord import SeqRecord
 
from Bio._utils import getattr_str, trim_str
from Bio.SearchIO._utils import singleitem, allitems, fullcascade, \
        fragcascade
                query_range = '[%s:%s]' % (query_start, query_end)
                # max column length is 20
                query_range = trim_str(query_range, 22, '~]')
                # hit region
                hit_start = getattr_str(block, 'hit_start')
                hit_end = getattr_str(block, 'hit_end')
                hit_range = '[%s:%s]' % (hit_start, hit_end)
                hit_range = trim_str(hit_range, 22, '~]')

src/b/i/biopython-HEAD/Bio/SearchIO/_model/hsp.py   biopython(Download)
from Bio.SeqRecord import SeqRecord
 
from Bio._utils import getattr_str, trim_str
from Bio.SearchIO._utils import singleitem, allitems, fullcascade, \
        fragcascade
                query_range = '[%s:%s]' % (query_start, query_end)
                # max column length is 20
                query_range = trim_str(query_range, 22, '~]')
                # hit region
                hit_start = getattr_str(block, 'hit_start')
                hit_end = getattr_str(block, 'hit_end')
                hit_range = '[%s:%s]' % (hit_start, hit_end)
                hit_range = trim_str(hit_range, 22, '~]')

src/b/i/biopython-1.63/Bio/SearchIO/_model/_base.py   biopython(Download)
 
 
from Bio._utils import getattr_str, trim_str
 
 
    def _str_hsp_header(self):
        """Prints the alignment header info."""
        lines = []
        # set query id line
        qid_line = trim_str('      Query: %s %s' %
                (self.query_id, self.query_description), 80, '...')
        # set hit id line
        hid_line = trim_str('        Hit: %s %s' %

src/b/i/biopython-HEAD/Bio/SearchIO/_model/_base.py   biopython(Download)
 
 
from Bio._utils import getattr_str, trim_str
 
 
    def _str_hsp_header(self):
        """Prints the alignment header info."""
        lines = []
        # set query id line
        qid_line = trim_str('      Query: %s %s' %
                (self.query_id, self.query_description), 80, '...')
        # set hit id line
        hid_line = trim_str('        Hit: %s %s' %

src/b/i/biopython-1.63/Bio/SearchIO/_model/query.py   biopython(Download)
from Bio._py3k import filter
 
from Bio._utils import trim_str
from Bio.SearchIO._utils import optionalcascade
 
            qid_line += ' (%i)' % self.seq_len
        if self.description:
            qid_line += trim_str('\n         %s' % self.description, 80, '...')
        lines.append(qid_line)
 

src/b/i/biopython-HEAD/Bio/SearchIO/_model/query.py   biopython(Download)
from Bio._py3k import filter
 
from Bio._utils import trim_str
from Bio.SearchIO._utils import optionalcascade
 
            qid_line += ' (%i)' % self.seq_len
        if self.description:
            qid_line += trim_str('\n         %s' % self.description, 80, '...')
        lines.append(qid_line)
 

src/b/i/biopython-1.63/Bio/Phylo/BaseTree.py   biopython(Download)
        def pair_as_kwarg_string(key, val):
            if isinstance(val, basestring):
                return "%s='%s'" % (key, _utils.trim_str(unicode(val), 60,
                    u'...'))
            return "%s=%s" % (key, val)
    def __str__(self):
        if self.name:
            return _utils.trim_str(self.name, 40, '...')
        return self.__class__.__name__
 

src/b/i/biopython-HEAD/Bio/Phylo/BaseTree.py   biopython(Download)
        def pair_as_kwarg_string(key, val):
            if isinstance(val, basestring):
                return "%s='%s'" % (key, _utils.trim_str(unicode(val), 60,
                    u'...'))
            return "%s=%s" % (key, val)
    def __str__(self):
        if self.name:
            return _utils.trim_str(self.name, 40, '...')
        return self.__class__.__name__