knots_to_speed {weathermetrics} | R Documentation |
Convert from knots to standard units of wind speed
Description
knots_to_speed
creates a numeric vector of speed, in units
specified by unit
, from a numeric vector of speed in knots.
Usage
knots_to_speed(knots, unit, round = 1)
Arguments
knots |
Numeric vector of speeds in knots |
unit |
Character specifying the speed unit other than knots. Possible values are:
|
round |
An integer indicating the number of decimal places to round the converted value. |
Details
Output will be in the speed units specified by unit
.
Value
A numeric vector of speeds (in the specified unit)
Note
Equations are from the source code for the National Oceanic and and Atmospheric Administration's online wind speed converter
Author(s)
Joshua Ferreri joshua.m.ferreri@gmail.com, Brooke Anderson brooke.anderson@colostate.edu
References
http://www.srh.noaa.gov/epz/?n=wxcalc_windconvert
See Also
Examples
data(foco)
foco$mph <- knots_to_speed(foco$knots, unit = "mph", round = 0)
foco$mps <- knots_to_speed(foco$knots, unit = "mps", round = NULL)
foco$ftps <- knots_to_speed(foco$knots, unit = "ftps")
foco$kmph <- knots_to_speed(foco$knots, unit = "kmph")
foco