Pandas has a new styling option for formatting CSS ( http://pandas.pydata.org/pandas-docs/version/0.17.1/generated/pandas.core.style.Styler.html ).
Previously, when I wanted to make my numbers in accounting / dollar terms, I would use something like below:
df = pd.DataFrame.from_dict({'10/01/2015': {'Issued': 200}}, orient='index') html = df.to_html(formatters={'Issued': format_money})
Format_money function:
def format_money(item): return '${:,.0f}'.format(item)
Now I want to use the style options and save the $ format. I see no way to do this.
Style formatting, for example, would look something like this:
s = df.style.bar(color='#009900')
This will add bars to my HTML table as shown below (Docs here: http://pandas.pydata.org/pandas-docs/stable/style.html ):

So, how can I do something like adding bars, and also save or add dollar formatting to the table? If I try to do this earlier, the style lines do not work, because now they cannot say that the data is numerical and there are no errors. If I try to do this after, it overrides the style.
source share