code: def numBlast(blast, numHits, evalueT = False, bitT = False, sort = False):
      
      if sort is True:
          for hit in numBlast_sort(blast, numHits, evalueT, bitT):
              yield hit
          return
      header = ['#query', 'target', 'pident', 'alen', 'mismatch', 'gapopen',
                'qstart', 'qend', 'tstart', 'tend', 'evalue', 'bitscore']
      yield header
      prev, hits = None, []
      for line in blast:
          line = line.strip().split('\t')
          ID = line[0]
          line[10], line[11] = float(line[10]), float(line[11])
          evalue, bit = line[10], line[11]
          if ID != prev:
              if len(hits) > 0:
                  # column is 1 + line index
                  for hit in top_hits(hits, numHits, 11, True):
                      yield hit
              hits = []
          if evalueT == False and bitT == False:
              hits.append(line)
          elif evalue <= evalueT and bitT == False:
              hits.append(line)
          elif evalue <= evalueT and bit >= bitT:
              hits.append(line)
          elif evalueT == False and bit >= bitT:
              hits.append(line)
          prev = ID
      for hit in top_hits(hits, numHits, 11, True):
          yield hit
docs: parse b6 output