熊猫to_html显示数据类型,如何仅显示值?

时间:2018-07-27 22:10:18

标签: python django pandas

我已经在这里阅读并搜索了互联网,但是没有人遇到同样的问题。当我使用to_html时,对于使用Django的网站,我得到的输出如下。如何仅显示值?并且没有如图所示的数据类型。

我在下面有一个列表:

l1 = []
l2 = []
l3 = []
l4 = []
l5 = []

amorttable = pd.DataFrame.from_records(list(zip(l1, l2, l3, l4,l5)),
                         columns=['Monthly_Payment', 'Interest', 'Principal', 'Remaining_Balance','Payment_Number'])

mortgageresult = amorttable.to_html(index=False)

result from pandas to_html

0 个答案:

没有答案
相关问题