salem.DataArrayAccessor.transform

DataArrayAccessor.transform(other, grid=None, interp='nearest', ks=3)

Reprojects an other Dataset or DataArray onto self.

The returned object has the same data structure as other (i.e. variables names, attributes), but is defined on the new grid (self.grid).

Parameters
other: Dataset, DataArray or ndarray

the data to project onto self

grid: salem.Grid

in case the input dataset does not carry georef info

interpstr

‘nearest’ (default), ‘linear’, or ‘spline’

ksint

Degree of the bivariate spline. Default is 3.

Returns
a dataset or a dataarray