metpy.calc.wind_components(speed, wind_direction)

Calculate the U, V wind vector components from the speed and direction.

  • speed (pint.Quantity) – Wind speed (magnitude)

  • wind_direction (pint.Quantity) – Wind direction, specified as the direction from which the wind is blowing (0-2 pi radians or 0-360 degrees), with 360 degrees being North.


u, v (tuple of pint.Quantity) – The wind components in the X (East-West) and Y (North-South) directions, respectively.


>>> from metpy.units import units
>>> metpy.calc.wind_components(10. * units('m/s'), 225. * units.deg)
 (<Quantity(7.07106781, 'meter / second')>, <Quantity(7.07106781, 'meter / second')>)

Changed in version 1.0: Renamed wdir parameter to wind_direction

Examples using metpy.calc.wind_components