3
Gibt es eine Möglichkeit, den Format-Stil (Anzahl der Dezimalstellen) für das Python-Modul tabulate
zu definieren?Python-Tabellennummer der Dezimalzahl
Zum Beispiel:
Ich habe die Nummer 3,34643745.
Ich möchte die Anzahl der Dezimalstellen formatieren, um nur zwei Dezimalstellen auszudrucken.
Ausgang: 3.34
Haben Sie [lesen Sie die Übersicht] (https: //pypi.python.org/pypi/tabulate)? Vielleicht Strg-F für "Dezimal" oder "Nummer"? – user2357112
https://pypi.python.org/pypi/tabulate#number-formatting – amiller27
Mögliches Duplikat der [Python-Format-Tabellenausgabe] (http://stackoverflow.com/questions/8356501/python-format-tabular-output) – wogsland