# HG changeset patch # User public-health-bioinformatics # Date 1666895591 0 # Node ID d848d37efb0c672ab654c5da6f3e5b63d417ff6a # Parent caeae8f3792c894a20a2067ca7d8759e83965a84 planemo upload for repository https://github.com/public-health-bioinformatics/galaxy_tools/blob/master/tools/adjust_bracken_for_unclassified_reads commit 24535690aedb81353cf5e036dc4577022d9604ad diff -r caeae8f3792c -r d848d37efb0c adjust_bracken_kreport_for_unclassified_reads.py --- a/adjust_bracken_kreport_for_unclassified_reads.py Thu Oct 27 18:11:07 2022 +0000 +++ b/adjust_bracken_kreport_for_unclassified_reads.py Thu Oct 27 18:33:11 2022 +0000 @@ -49,7 +49,7 @@ writer = csv.DictWriter(sys.stdout, fieldnames=output_fieldnames, dialect='excel-tab') bracken_unclassified_entry = { - 'percentage': '{:.3f}'.format(kraken_report_unclassified_seqs / total_seqs * 100), + 'percentage': '{:.2f}'.format(kraken_report_unclassified_seqs / total_seqs * 100), 'seqs_total': kraken_report_unclassified_seqs, 'seqs_this_level': kraken_report_unclassified_seqs, 'taxonomic_level': 'U', @@ -58,7 +58,7 @@ } for row in kraken_style_bracken_report: - row['percentage'] = '{:.3f}'.format(row['seqs_total'] / total_seqs * 100) + row['percentage'] = '{:.2f}'.format(row['seqs_total'] / total_seqs * 100) kraken_style_bracken_report_with_unclassified = [bracken_unclassified_entry] + kraken_style_bracken_report for row in kraken_style_bracken_report_with_unclassified: