Main Content
matlab.io.hdfeos.sw.setFillValue
Namespace: matlab.io.hdfeos.sw
Set fill value for the specified field
Syntax
setFillValue(swathID,fieldname,fillvalue)
Description
setFillValue(swathID,fieldname,fillvalue)
sets
the fill value for the specified field. The field must have more
than two dimensions.
This function corresponds to the SWsetfillvalue
function
in the HDF-EOS library C API.
Examples
import matlab.io.hdfeos.* swfid = sw.open('myfile.hdf','create'); swathID = sw.create(swfid,'MySwath'); sw.defDim(swathID,'Track',400); sw.defDim(swathID,'Xtrack',200); dims = {'Track','Xtrack'}; sw.defDataField(swathID,'Temperature',dims,'float'); sw.setFillValue(swathID,'Temperature',single(-999)); sw.detach(swathID); sw.close(swfid);