Closed
Description
Bug report
I recently upgraded to v2.0.0 and noticed that the new imshow interpolation is not honoring masked values. This is likely related to the new edge handling, described here: http://matplotlib.org/examples/pylab_examples/image_interp.html
Code for reproduction
a = np.random.random((7,7))*1000
ndv = -9999.0
a[2:4,1:5] = ndv
am = np.ma.masked_equal(a, ndv)
plt.figure()
#Plot with no interpolation, looks fine
plt.imshow(am, interpolation='none')
plt.title("interpolation='none'")
#Plot with bilinear interpolation, the -9999.0 values are used
plt.imshow(am, interpolation='bilinear')
plt.title("interpolation='bilinear'")
Actual outcome
Expected outcome
The interpolation should ignore masked values as in previous versions.
Matplotlib version
- Matplotlib v2.0.0, Python 2.7.13, OSX
- installed from pip