I am trying to add thousands comma separator to the displayed values above each bar in the plot below (example, (currently) 13815 (want to be) 13,815). I am able to do so for the y-axis. Please advise!
My code looks like this:
a = df.opp.value_counts().plot(kind='bar')
#annotate bar plot with values
for p in a.patches:
a.annotate(str(p.get_height()), (p.get_x() * 1.005, p.get_height() * 1.005))
a.set_yticklabels(['{:,}'.format(int(x)) for x in bar_uk19_opptype.get_yticks().tolist()])