def _stream_tp_rows(self, stream_output, percent_by_rank_by_taxid, strain_id_to_genome_id, genome_id_to_otu):
    '\n        Stream the rows of the taxonomic profile.\n\n        @param stream_output: Output of taxonomic profile\n        @type stream_output: file | FileIO | StringIO\n        @param percent_by_rank_by_taxid: Percentage for each taxid of a list of default ranks as dictionary of dictionaries\n        @type percent_by_rank_by_taxid: dict[str|unicode, dict[str|unicode, float]]\n        @param strain_id_to_genome_id: Map from strain id to a genome identifier\n        @type strain_id_to_genome_id: dict[str|unicode, str|unicode]\n        @param genome_id_to_otu: Map from genome id to an otu identifier\n        @type genome_id_to_otu: dict[str|unicode, str|unicode]\n        '
    row_format = '{taxid}\t{rank}\t{taxpath}\t{taxpath_sn}\t{abp:.4f}\t{gid}\t{otu}\n'
    for (rank_index, rank) in enumerate(self._ranks):
        for tax_id in percent_by_rank_by_taxid[rank]:
            if (tax_id == ''):
                self._logger.warning(('Missing rank %s for a genome' % rank))
                continue
            if ('.' in tax_id):
                genome_id = strain_id_to_genome_id[tax_id]
                otu = genome_id_to_otu[genome_id]
                lineage = self._taxonomy.get_lineage_of_legal_ranks(tax_id.split('.')[0], ranks=self._ranks, default_value='')
                lineage[(- 1)] = tax_id
            else:
                genome_id = ''
                otu = ''
                lineage = self._taxonomy.get_lineage_of_legal_ranks(tax_id, ranks=self._ranks, default_value='')
            lineage = lineage[:(rank_index + 1)]
            lineage_sn = [(self._taxonomy.get_scientific_name(tid) if ((tid != '') and ('.' not in tid)) else '') for tid in lineage]
            if ('.' in tax_id):
                lineage_sn[(- 1)] = (self._taxonomy.get_scientific_name(tax_id.split('.')[0]) + ' strain')
            if (percent_by_rank_by_taxid[rank][tax_id] != 0):
                stream_output.write(row_format.format(taxid=tax_id, rank=rank, taxpath='|'.join(lineage), taxpath_sn='|'.join(lineage_sn), abp=(percent_by_rank_by_taxid[rank][tax_id] * 100), gid=genome_id, otu=otu))
Stream the rows of the taxonomic profile.

@param stream_output: Output of taxonomic profile
@type stream_output: file | FileIO | StringIO
@param percent_by_rank_by_taxid: Percentage for each taxid of a list of default ranks as dictionary of dictionaries
@type percent_by_rank_by_taxid: dict[str|unicode, dict[str|unicode, float]]
@param strain_id_to_genome_id: Map from strain id to a genome identifier
@type strain_id_to_genome_id: dict[str|unicode, str|unicode]
@param genome_id_to_otu: Map from genome id to an otu identifier
@type genome_id_to_otu: dict[str|unicode, str|unicode]
def _stream_tp_rows(self, stream_output, percent_by_rank_by_taxid, strain_id_to_genome_id, genome_id_to_otu):
    '\n        Stream the rows of the taxonomic profile.\n\n        @param stream_output: Output of taxonomic profile\n        @type stream_output: file | FileIO | StringIO\n        @param percent_by_rank_by_taxid: Percentage for each taxid of a list of default ranks as dictionary of dictionaries\n        @type percent_by_rank_by_taxid: dict[str|unicode, dict[str|unicode, float]]\n        @param strain_id_to_genome_id: Map from strain id to a genome identifier\n        @type strain_id_to_genome_id: dict[str|unicode, str|unicode]\n        @param genome_id_to_otu: Map from genome id to an otu identifier\n        @type genome_id_to_otu: dict[str|unicode, str|unicode]\n        '
    row_format = '{taxid}\t{rank}\t{taxpath}\t{taxpath_sn}\t{abp:.4f}\t{gid}\t{otu}\n'
    for (rank_index, rank) in enumerate(self._ranks):
        for tax_id in percent_by_rank_by_taxid[rank]:
            if (tax_id == ):
                self._logger.warning(('Missing rank %s for a genome' % rank))
                continue
            if ('.' in tax_id):
                genome_id = strain_id_to_genome_id[tax_id]
                otu = genome_id_to_otu[genome_id]
                lineage = self._taxonomy.get_lineage_of_legal_ranks(tax_id.split('.')[0], ranks=self._ranks, default_value=)
                lineage[(- 1)] = tax_id
            else:
                genome_id = 
                otu = 
                lineage = self._taxonomy.get_lineage_of_legal_ranks(tax_id, ranks=self._ranks, default_value=)
            lineage = lineage[:(rank_index + 1)]
            lineage_sn = [(self._taxonomy.get_scientific_name(tid) if ((tid != ) and ('.' not in tid)) else ) for tid in lineage]
            if ('.' in tax_id):
                lineage_sn[(- 1)] = (self._taxonomy.get_scientific_name(tax_id.split('.')[0]) + ' strain')
            if (percent_by_rank_by_taxid[rank][tax_id] != 0):
                stream_output.write(row_format.format(taxid=tax_id, rank=rank, taxpath='|'.join(lineage), taxpath_sn='|'.join(lineage_sn), abp=(percent_by_rank_by_taxid[rank][tax_id] * 100), gid=genome_id, otu=otu))