Calculate the resultant wind speed and direction from a collection of wind speeds and directions.
res_wind_speed(speed, dir, na.rm = TRUE)
res_wind_dir(speed, dir, na.rm = TRUE)
Wind speeds.
Wind directions in degrees clockwise from north.
A logical value indicating whether NA
values should be
stripped before the computation proceeds.
res_wind_speed
returns the resultant wind
speed. res_wind_dir
returns the resultant wind direction.
Resultant wind speeds are vector-averaged. We first find the average values of the east-west and north-south components,
$$V_e = -\frac{1}{N} \sum u_i \sin(\theta_i)$$ $$V_n = -\frac{1}{N} \sum u_i \cos(\theta_i)$$
where \(u\) is the speed and \(\theta\) is the direction. The resultant speed and direction can then be calculated with
$$U_R = \sqrt{V_e^2 + V_n^2}$$ $$\theta_R = \textrm{arctan}(\frac{V_e}{V_n}) + 180$$
U.S. Environmental Protection Agency (2000). “Meteorological Monitoring Guidance for Regulatory Modeling Applications.” https://www.epa.gov/sites/production/files/2020-10/documents/mmgrma_0.pdf.