Skip to content

Commit 066cfe0

Browse files
committed
DOC spectral is now deprecated in favor of nipy_spectral
The documentation now uses nipy_spectral
1 parent c708871 commit 066cfe0

File tree

3 files changed

+4
-5
lines changed

3 files changed

+4
-5
lines changed

doc/users/image_tutorial.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ Note that you can also change colormaps on existing plot objects using the
203203
.. sourcecode:: ipython
204204

205205
In [10]: imgplot = plt.imshow(lum_img)
206-
In [11]: imgplot.set_cmap('spectral')
206+
In [11]: imgplot.set_cmap('nipy_spectral')
207207

208208
.. plot::
209209

@@ -213,7 +213,7 @@ Note that you can also change colormaps on existing plot objects using the
213213
img = mpimg.imread('../_static/stinkbug.png')
214214
lum_img = img[:, :, 0]
215215
imgplot = plt.imshow(lum_img)
216-
imgplot.set_cmap('spectral')
216+
imgplot.set_cmap('nipy_spectral')
217217

218218
.. note::
219219

@@ -249,7 +249,7 @@ do that by adding color bars.
249249
img = mpimg.imread('../_static/stinkbug.png')
250250
lum_img = img[:, :, 0]
251251
imgplot = plt.imshow(lum_img)
252-
imgplot.set_cmap('spectral')
252+
imgplot.set_cmap('nipy_spectral')
253253
plt.colorbar()
254254

255255
This adds a colorbar to your existing figure. This won't

lib/matplotlib/pylab.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,6 @@
121121
spring - set the default colormap to spring
122122
summer - set the default colormap to summer
123123
winter - set the default colormap to winter
124-
spectral - set the default colormap to spectral
125124
126125
_Event handling
127126

lib/mpl_toolkits/tests/test_axes_grid.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def test_imagegrid_cbar_mode_edge():
2929
cbar_mode='edge')
3030
ax1, ax2, ax3, ax4, = grid
3131

32-
im1 = ax1.imshow(arr.real, cmap='spectral')
32+
im1 = ax1.imshow(arr.real, cmap='nipy_spectral')
3333
im2 = ax2.imshow(arr.imag, cmap='hot')
3434
im3 = ax3.imshow(np.abs(arr), cmap='jet')
3535
im4 = ax4.imshow(np.arctan2(arr.imag, arr.real), cmap='hsv')

0 commit comments

Comments
 (0)