Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit ea31477

Browse filesBrowse files
committed
DOC: Show Lightness label for every colormap Axes.
It's not really any clearer to have a single label per `Figure`, since in the docs every figure just appears one after the other. Fixes #16801.
1 parent 6925bf6 commit ea31477
Copy full SHA for ea31477

File tree

Expand file treeCollapse file tree

1 file changed

+2
-3
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+2
-3
lines changed

‎tutorials/colors/colormaps.py

Copy file name to clipboardExpand all lines: tutorials/colors/colormaps.py
+2-3Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ def plot_color_gradients(cmap_category, cmap_list, nrows):
225225
plt.show()
226226

227227
###############################################################################
228-
# Lightness of matplotlib colormaps
228+
# Lightness of Matplotlib colormaps
229229
# =================================
230230
#
231231
# Here we examine the lightness values of the matplotlib colormaps.
@@ -308,10 +308,9 @@ def plot_color_gradients(cmap_category, cmap_list, nrows):
308308
formatter = mpl.ticker.FixedFormatter(cmap_list[i*dsub:(i+1)*dsub])
309309
ax.xaxis.set_major_formatter(formatter)
310310
ax.xaxis.set_tick_params(rotation=50)
311+
ax.set_ylabel('Lightness $L^*$', fontsize=12)
311312

312313
ax.set_xlabel(cmap_category + ' colormaps', fontsize=14)
313-
fig.text(0.0, 0.55, 'Lightness $L^*$', fontsize=12,
314-
transform=fig.transFigure, rotation=90)
315314

316315
fig.tight_layout(h_pad=0.0, pad=1.5)
317316
plt.show()

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.