NCEP.uv.revert {RNCEP} | R Documentation |
Reverts speed and direction to U and V components.
Description
This function calculates U (i.e. zonal or east/west) and V (i.e. meridional or north/south) components from a specified speed and direction.
Usage
NCEP.uv.revert(spd, dir, radians=FALSE)
Arguments
spd |
A numeric value indicating speed. |
dir |
A numeric value indicating direction in degrees from north or radians if |
radians |
A logical indicating whether |
Details
This function calculates U (i.e. zonal or east/west) and V (i.e. meridional or north/south) components from a specified speed and direction. U and V components describe the direction into which movement occurs with east and north being positive, respectively. If directions are given in radians, radians
must be set to TRUE
.
Value
A data.frame
containing U and V components given in the same units as speed
.
Author(s)
Michael U. Kemp mukemp+RNCEP@gmail.com
References
To cite package 'RNCEP' in publications use:
Kemp, M. U., van Loon, E. E., Shamoun-Baranes, J., and Bouten, W. 2011. RNCEP:global weather and climate data at your fingertips. – Methods in Ecology and Evolution. DOI:10.1111/j.2041-210X.2011.00138.x.
Examples
library(RNCEP)
## Using NCEP.uv.revert ##
NCEP.uv.revert(spd=12, dir=225, radians=FALSE)