pyinterp.core.RTree3DFloat32.universal_kriging#

RTree3DFloat32.universal_kriging(self: pyinterp.core.RTree3DFloat32, coordinates: numpy.ndarray[numpy.float32], radius: Optional[float] = None, k: int = 9, covariance: pyinterp.core.CovarianceFunction = <CovarianceFunction.Matern_32: 1>, sigma: float = 1, alpha: float = 1000000, within: bool = True, num_threads: int = 0) tuple#

Universal Kriging interpolation of the value at the requested position.

Parameters:
  • coordinates – a matrix (n, 3) where n is the number of observations and 3 is the number of coordinates in order: longitude and latitude in degrees and altitude in meters. If the shape of the matrix is (n, 2) then the method considers the altitude constant and equal to zero.

  • radius – The maximum radius of the search (m). Default to the largest value that can be represented on a float.

  • k – The number of nearest neighbors to be used for calculating the interpolated value. Defaults to 9.

  • covariance – The covariance function to be used. Defaults to pyinterp.core.CovarianceFunction.Matern_52.

  • sigma – The magnitude parameter. Determines the overall scale of the covariance function. It represents the maximum possible covariance between two points. Defaults to 1.

  • alpha – Decay rate parameter. Determines the rate at which the covariance decreases. It represents the spatial scale of the covariance function and can be used to control the smoothness of the spatial dependence structure.

  • within – If true, the method ensures that the neighbors found are located around the point of interest. Defaults to true.

  • num_threads – The number of threads to use for the computation. If 0 all CPUs are used. If 1 is given, no parallel computing code is used at all, which is useful for debugging. Defaults to 0.

Returns:

The interpolated value and the number of neighbors used for the calculation.