radarx.retrieve.disdrometer.radar_at_location#

radarx.retrieve.disdrometer.radar_at_location(obj, latitude, longitude, altitude=None, *, sweep=0, data_vars=None, radius=None)[source]#

Radar variables in the gate above a ground location.

Parameters:
  • obj (xarray.DataTree, xarray.Dataset or sequence of them) – Radar volumes (xradar DataTrees) or sweeps, e.g. one volume per time; each gives one sample.

  • latitude, longitude (float) – Location (degrees north and east), e.g. a disdrometer.

  • altitude (float, optional) – Altitude of the location (m above sea level). Default: the radar altitude.

  • sweep (int or float, optional) – Sweep index (sweep_<n>, default 0) or the fixed angle (degrees) of the sweep to take from DataTrees.

  • data_vars (sequence of str, optional) – Variables to sample. Default: all variables on (azimuth, range).

  • radius (float, optional) – Average the gates whose centres are within this horizontal distance (m) of the location (variables in dB averaged in linear units) instead of taking the nearest gate.

Returns:

xarray.Dataset – On time (time of the sampled ray): the fields, and beam_height (m above sea level), height_above_ground (beam height above the location), gate_distance (horizontal distance from the gate to the location, m), range, azimuth and elevation of the gate. The beam is a straight line on an Earth of 4/3 its radius.

Notes

No published method is implemented here: the gate sampling is radarx’s own, and the beam height is that of radarx.fundamentals.geometry.beam_center_height() (4/3 effective Earth radius; see that function). The location is placed from the radar by the geodesic distance and bearing on the WGS84 ellipsoid (a sphere of 6371 km, used earlier, is off by -0.2 to +0.56 %, up to 280 m at 50 km).

Dask. This function computes the dask array: it reads the gates above one location. The input is loaded into memory and the result is held in memory.