Skip To Content

Swath function

Some netCDF or HDF datasets store their geolocation as irregularly spaced arrays. When adding these datasets to a mosaic dataset, the swath function takes the irregularly gridded data and resamples it so that each pixel is of uniform size and is square.

When adding variables from netCDF or HDF to a mosaic dataset, it will automatically verify if the data is arrayed regularly. If it is not, the swath function is applied automatically to convert the irregular raster into points and then to a regularly gridded raster. You can change the interpolation method and cell size used in the swath raster function. For regular-spaced raster data, no interpolation will be applied, data will be read as it is.

There are 4 resampling methods for this function:

  • Nearest Neighbor—Calculates pixel value using the nearest pixel. If no source pixel exists, then no new pixel can be created in the output.
  • Bilinear Interpolation—Calculates pixel value using the distance-weighted value of four nearest pixels.
  • Linear tinning—Uses a triangular irregular network from the center points of each cell in the irregular raster to interpolate a surface which is then converted to a regular raster.
  • Natural Neighbor— Performs a nearest neighbor assignment, is the fastest of the interpolation methods. It is used primarily for discrete data, such as a land-use classification, since it will not change the values of the cells. The maximum spatial error will be one-half the cell size.

Cell Size—The cell size for the output raster will be automatically detected; however, you can change this if you want to. The cell size can be changed, but the extent of the raster dataset will remain the same.

Related topics