Peter Chao Peter Chao - 2 years ago 175
Python Question

use python pandas convert csv to html

I have a csv file and need to convert to html format. I know python pandas can do it with DataFormat.to_html(), but could not figure out what value to put in the (). I have:
pd.DataFrame.to_html(class=myfile.csv) but got issue with it.

Anyone has idea?

Answer Source

You need to put there dataframe:

df = pd.read_csv("myfile.csv")
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download