I am new to Python and figured out that I can plot color maps the following way:
import matplotlib.pyplot as plt
#some image generating code
plot = plt.imshow(image)
plot.set_cmap(cmap)
plot.set_interpolation(interpolation_method)
plt.show()
Where image is an 2-dimensional numpy array in my case. As result I get a beautiful colormap (could not post an image of it since I am new to this platform). Link to my color map: http://s7.directupload.net/images/131017/t9aczkmq.png)
My Question
Is there a way to display the current value of a position/pixel in the upper colormap on mouse hovering? I need to display the actual value (within the array that has been plotted) not the color value.
Additional Question
Is there also a way to add a slicer to the output in order to change the cuts of the color map dynamically (similar to a FITS viewer).
Probably I just need the right modules, but I could not find any fitting my needs yet. Thanks in advance!