wind_components#
- metpy.calc.wind_components(speed, wind_direction)#
Calculate the U, V wind vector components from the speed and direction.
- Parameters
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.
- Returns
u, v (tuple of
pint.Quantity
) – The wind components in the X (East-West) and Y (North-South) directions, respectively.
See also
Examples
>>> from metpy.calc import wind_components >>> from metpy.units import units >>> 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 towind_direction
Examples using metpy.calc.wind_components
#
Advanced Sounding
Bulk Shear
Sounding Calculation Examples
Wind and Sea Level Pressure Interpolation
Wind and Sea Level Pressure Interpolation
Skew-T with Complex Layout
Hodograph Inset
Sounding as Dataset Example
Simple Sounding
Mesonet Station Plot
Station Plot with Layout
Upper Air Sounding Tutorial