Matplotlib – Rotate label text in seaborn factorplot


I have a simple factorplot

import seaborn as sns
g = sns.factorplot("name", "miss_ratio", "policy", dodge=.2, 
    linestyles=["none", "none", "none", "none"], data=df[df["level"] == 2])

enter image description here

The problem is that the x labels all run together, making them unreadable. How do you rotate the text so that the labels are readable?

Best Answer

I had a problem with the answer by @mwaskorn, namely that


fails, because this also requires the labels. A bit easier than the answer by @Aman is to just add

Related Question