environmentaltools.spatiotemporal.bme.smooth_data

environmentaltools.spatiotemporal.bme.smooth_data(ck, chs, zhs, v, nmax, dmax)[source]

Apply spatial smoothing to data using exponential distance weighting.

Performs kernel smoothing on spatiotemporal data to reduce noise.

Parameters:
  • ck (pd.DataFrame) – Estimation point coordinates with columns [‘x’, ‘y’, ‘t’].

  • chs (pd.DataFrame) – Data point coordinates with columns [‘x’, ‘y’, ‘t’].

  • zhs (pd.DataFrame) – Data values.

  • v (float) – Bandwidth parameter for exponential kernel.

  • nmax (int) – Maximum number of neighbors to use.

  • dmax (list of float) – Maximum distances [spatial_max, temporal_max, space_time_ratio].

Returns:

zk – Smoothed values at estimation points.

Return type:

np.ndarray

Notes

Uses exponential kernel: weight = exp(-distance / v). Weights are normalized to sum to 1 for each estimation point.