python - How do I change the font family of matplotlib bar chart labels? -
this question has answer here:
- how change fonts in matplotlib (python)? 4 answers
i'm using following line add labels bar chart, how can adjust font family?
plt.xticks(xticks_pos, labels, ha='right', rotation=55, fontsize=20)
you can use fontname shown in this question.
plt.xticks(xticks_pos, labels, ha='right', rotation=55, fontsize=20, fontname='monospace')
Comments
Post a Comment