Last modified: Fri, 06/16/2017 - 16:24
RECT_TO_CURV (V, lon_bounds_out, lat_bounds_out, missing_allowed) Uses Bilinear Interpolation to regrid data on a recilinear grid to a curvilinear grid.
Arguments: |
V |
Variable on the source rectilinear grid |
lon_bounds_out |
Destination grid longitudes, in degrees (2-D field of longitudes describing the curvilinear grid) |
|
lat_bounds_out |
Destination grid latitudes, in degrees (2-D field of latitudes describing the curvilinear grid) |
|
missing_allowed |
Number of missing values allowed among the 4 surrounding source cells: 0 to 3 |
|
Result Axes: |
X |
Inherited from lon_bounds_out |
Y |
Inherited from lat_bounds_out |
|
Z |
Inherited from V |
|
T |
Inherited from V |
Example: put a rectilinear data set on a curvilinear grid for comparison.
yes? use my_curvilinear_data.nc yes? use levitus_climatology yes? show data currently SET data sets: 1> /.my_curvilinear_data.nc name title I J K L GEOLON geographic longitude of grid 1:180 1:173 ... ... GEOLAT geographic latitude of grid 1:180 1:173 ... ... SALT salinity 1:180 1:173 1:30 1:12 AIRT air temperature 1:180 1:173 1:30 1:12 2> /home/ja9/tmap/fer_dsets/data/levitus_climatology.cdf (default) name title I J K L TEMP TEMPERATURE 1:360 1:180 1:20 ... SALT SALINITY 1:360 1:180 1:20 ... yes? ! For convenience, define variables for arguments to RECT_TO_CURV yes? let lonout = geolon[d=1] yes? let latout = geolat[d=1] yes? let a = rect_to_curv(temp[d=2,k=1], lonout, latout, 2) yes? shade a, lonout, latout yes? ! Compare to a variable on the curvilinear grid yes? shade a-airt[d=1], lonout, latout yes? ! save the new variable for all depths, with the curvilinear yes? ! latitude and longitude variables yes? let temp_curv = rect_to_curv(temp[d=2], lonout, latout, 2) yes? save/file=tcurv.nc temp_curv, lonout, latout LISTing to file tcurv.nc