Question

I want to do two subplots with imshow using the same colormap by which I mean: if points in both plots have the same color, they correspond to the same value. But how can I get imshow to use only 9/10 or so of the colormap for the first plot, because it's maximal value is only 9/10 of the maximal value in the second plot?

Thanks, Alice

Était-ce utile?

La solution

imgshow takes two arguments vmin and vmax for the color scale. You could do what you want by putting the same vmin and vmax for both your subplots.

To find vmin you can take the minimum between the minimum of all the values in your data (and same reasoning for vmax).

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top