Main Content
matlab.io.hdfeos.gd.interpolate
Namespace: matlab.io.hdfeos.gd
Bilinear interpolation on a grid field
Syntax
data = interpolate(gridID,lat,lon,fieldname)
Description
data = interpolate(gridID,lat,lon,fieldname)
performs
bilinear interpolation on lat/lon pairs from the data in the grid
field.
data
contains the interpolated field values.
This function corresponds to the GDinterpolate
function
in the HDF-EOS library C API.
Examples
import matlab.io.hdfeos.* gfid = gd.open('example.hdf'); gridID = gd.attach(gfid,'MonthlyRain'); [lat,lon] = gd.ij2ll(gridID,[18 18],[14 15]); data = gd.interpolate(gridID,lat,lon,'TbOceanRain'); gd.detach(gridID); gd.close(gfid);