[ncl-talk] extract some grids with given lat and lon from global netcdf
Jiaxin Zhang
jiaxinzhang3 at gmail.com
Wed Aug 13 19:03:57 MDT 2014
Dear NCL users,
I want to extract a few grids with given lon and lat from global netcdf of
CMIP5.
I have extracted one grid in a specific lat and lon using the attcahed
script ("extract_grid.ncl") for site1, but I did this part manually (I mean
I had to look at all the values of lat and lon in the global netcdf, found
the ones that were the closest to the given lat and lon and use the lat and
lon indices that correspond to this grid to extract it). I guess that there
are most efficient ways to do this, right? What is the best way to do it?
What would be the recommended way to simoultaneously extract moret han one
grid (for instance site1, site2 and site3)?
In addition, some of the files that correspond to different CMIP5 models
have different spatial resolution, and this means that the lat and lon for
the same location would have different indices for lat and lon in different
models.
Could you please give some adivice about the best way to extract some grids
(in specific lat and lon) from global netcdf with different spatial
resolution?
Attached is the code I used for site 1. Also attached are two different
global netcdf (for just 1 time) from 2 models that use different spatial
resolution. Is it possible to modify the script so I can use it for netcdf
with different spatial resolutions?
Thank you!
Jiaxin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20140813/41ce9990/attachment.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: extract_grid.ncl
Type: application/octet-stream
Size: 906 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20140813/41ce9990/attachment.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cVeg_CanESM2_1time.nc
Type: application/x-netcdf
Size: 35544 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20140813/41ce9990/attachment.nc
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cVeg_NorESM1-M_1time.nc
Type: application/x-netcdf
Size: 58524 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20140813/41ce9990/attachment-0001.nc
More information about the ncl-talk
mailing list