remap: result does not match target grid
Added by Jay Su about 5 years ago
We are remapping data1 (lon=[-180,180]) to grid (lon = [0,360]).
If asked: [0,360], no issue
but if asked: [-180,180], the result will on the grid [-180,180] instead of [0,360]
Does it cause any issue to any tool? I understand [-180,180] = [0,360].
Thanks,
Replies (3)
RE: remap: result does not match target grid - Added by Ralf Mueller about 5 years ago
Jay Su wrote:
We are remapping data1 (lon=[-180,180]) to grid (lon = [0,360]).
If asked: [0,360], no issue
but if asked: [-180,180], the result will on the grid [-180,180] instead of [0,360]
well, you get, what you asked for. so i think this is correct behavior of CDO, isn't it?
Does it cause any issue to any tool? I understand [-180,180] = [0,360].
are you serious? How could anybody know all tools? Sure, [-180,180] and [0,360] describe the same thing, but tools have to be aware of that. CDO is,btw.
Thanks,
RE: remap: result does not match target grid - Added by Jay Su about 5 years ago
Well the user also asks for the grid [0,360]... Does it mean CDO puts subsetting parameters above grid parameters?
No I did not ask about all tools, just the tools you may be aware of.
RE: remap: result does not match target grid - Added by Ralf Mueller about 5 years ago
Jay Su wrote:
Well the user also asks for the grid [0,360]... Does it mean CDO puts subsetting parameters above grid parameters?
CDI does as requested by the user. For a -180,+180 grid, you can user this griddes (the internal default called global_1
)
# # gridID 1 # gridtype = lonlat gridsize = 64800 xsize = 360 ysize = 180 xname = lon xlongname = "longitude" xunits = "degrees_east" yname = lat ylongname = "latitude" yunits = "degrees_north" xfirst = 0.5 xinc = 1 yfirst = -89.5 yinc = 1whereas the version for 0,360 looks nearly identical
# # gridID 1 # gridtype = lonlat gridsize = 64800 xsize = 360 ysize = 180 xname = lon xlongname = "longitude" xunits = "degrees_east" yname = lat ylongname = "latitude" yunits = "degrees_north" xfirst = 0.5 xinc = 1 yfirst = -89.5 yinc = 1Only the
xfirst
value is different. Both can be used for remapping and will create the corresponding grids.
No I did not ask about all tools, just the tools you may be aware of.
Sorry for the misunderstanding, then - CDO can handle this, plotting tools like Panoply, ncview and ncl can handle this. general mapping tools like python-libraries for plotting for sure can handle this.
Finally: Since this identity is so fundamental I expect all tools to work with this. But: Please check yoursef ;-)
hth
ralf
global_1_180 (280 Bytes) global_1_180 | |||
global_1_360 (280 Bytes) global_1_360 |