I want to use the 'terrain' colormap but I want it to start at the green colors and not de blues. How can I do that?
Specifically, how can I change a colormap to start at another color of the same colormap??.
I have this:
import matplotlib.pyplot as plt
levels = [0,100,250,500,800,1250,1600,2000,2500,3000,4000,5000]
palette = plt.get_cmap('terrain')
fig, ax = plt.subplots()
C = ax.contourf(lon, lat, hgt,
cmap = paleta,
extend='max',
levels=levels)
cbar=plt.colorbar(C,ticks=levels,spacing='proportional')
cbar.set_label('m',fontsize=18)
cbar.ax.yaxis.set_ticklabels(levels,fontsize=18)
Any suggestions? Thank you very much