stats: Set message count columns in types command to integers

pull/1/head
Michael DM Dryden 2020-06-06 18:32:39 -04:00
rodzic 1fd965c5e2
commit ca62866e0e
1 zmienionych plików z 5 dodań i 0 usunięć

Wyświetl plik

@ -709,6 +709,11 @@ class StatsRunner(object):
a = list(zip(df.columns.values, ["Total"] + df.iloc[:, 1:].sum().to_list()))
df = df.append({key: value for key, value in a}, ignore_index=True)
df['Group Count'] = df['Group Count'].astype('Int64')
try:
df['User Count'] = df['User Count'].astype('Int64')
except KeyError:
pass
text = df.to_string(index=False, header=True, float_format=lambda x: f"{x:.1f}")
if user: