change the range of the colorbar #1079
Replies: 6 comments 1 reply
-
Hi, you should use vmin and vmax, not zmin and zmax (same as standard matplotlib) |
Beta Was this translation helpful? Give feedback.
-
Valentina, try cmin and cmax, instead of zmin zmax |
Beta Was this translation helpful? Give feedback.
-
Hm, it is supposed to be vmin and vmax. |
Beta Was this translation helpful? Give feedback.
-
Hi Knut, It is a backwards simulation. The release points are between 0 and 200m, that is why we want to restrict the colorbar to -200m to 0m. |
Beta Was this translation helpful? Give feedback.
-
Ok. You can also check the actual depths with |
Beta Was this translation helpful? Give feedback.
-
Well, some particles do go deeper than 200m in their backward trajectory, but our areas of interest (origin areas) are also shallow, so we want the colorbar to only spam -200 to 0m |
Beta Was this translation helpful? Give feedback.
-
Hello Team,
¿How can i change the range of the colorbar between -200 and 0 in the graphic?
##################################
import os
import opendrift
import numpy as np
o = opendrift.open("archivo.nc",elements=np.arange(0,587160,500))
o.plot(buffer=.2, fast=True, linecolor = 'z',zmin=-200,zmax=0,filename='archivo.png')
Beta Was this translation helpful? Give feedback.
All reactions