Skip to content

Commit

Permalink
Set heatmap yticklabel alignment while rotating (#2574)
Browse files Browse the repository at this point in the history
* Set heatmap yticklabel alignment while rotating

Closes #2484

* Update release notes [skip ci]
  • Loading branch information
mwaskom authored May 6, 2021
1 parent a41703e commit 430c1bf
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions doc/releases/v0.12.0.txt
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ A paper describing seaborn was published in the `Journal of Open Source Software

- |Fix| In :func:`displot`, fixed a bug where `common_norm` was ignored when `kind="hist"` and faceting was used without assigning `hue` (:pr:`2468`).

- |Fix| In :func:`heatmap`, fixed a bug where vertically-rotated y-axis tick labels would be misaligned with their rows (:pr:`2574`).

- |Defaults| In :func:`displot`, the default alpha value now adjusts to a provided `multiple` parameter even when `hue` is not assigned (:pr:`2462`).

- |Docs| Improved the API documentation for theme-related functions (:pr:`2573`).
Expand Down
1 change: 1 addition & 0 deletions seaborn/matrix.py
Original file line number Diff line number Diff line change
Expand Up @@ -334,6 +334,7 @@ def plot(self, ax, cax, kws):
ax.set(xticks=xticks, yticks=yticks)
xtl = ax.set_xticklabels(xticklabels)
ytl = ax.set_yticklabels(yticklabels, rotation="vertical")
plt.setp(ytl, va="center") # GH2484

# Possibly rotate them if they overlap
_draw_figure(ax.figure)
Expand Down

0 comments on commit 430c1bf

Please sign in to comment.