earthkit.meteo.wind.array.direction =================================== .. py:function:: earthkit.meteo.wind.array.direction(u, v, convention='meteo', to_positive=True) Compute the direction/angle of a vector quantity. :param u: u wind/x vector component :type u: :class:`array-like` :param v: v wind/y vector component (same units as ``u``) :type v: :class:`array-like` :param convention: Specify how the direction/angle is interpreted. The possible values are as follows: * "meteo": the direction is the meteorological wind direction (see below for explanation) * "polar": the direction is measured anti-clockwise from the x axis (East/right) to the vector :type convention: :class:`str`, *optional* :param to_positive: If it is True the resulting values are mapped into the [0, 360] range when ``convention`` is "polar". Otherwise they lie in the [-180, 180] range. :type to_positive: :class:`bool`, *optional* :returns: Direction/angle (degrees) :rtype: :class:`array-like` The meteorological wind direction is the direction from which the wind is blowing. Wind direction increases clockwise such that a northerly wind is 0°, an easterly wind is 90°, a southerly wind is 180°, and a westerly wind is 270°. The figure below illustrates how it is related to the actual orientation of the wind vector: .. image:: /_static/wind_direction.png :width: 400px