Skip to contents

Traditional wind rose plot

Usage

rose_pollution(
  data,
  pollutant,
  angle = 30,
  facet = NULL,
  bias_corr = TRUE,
  breaks = 6,
  normalise = FALSE,
  statistic = "prop.count",
  width = 0.9,
  border_colour = NA,
  alpha = 1
)

Arguments

data

A data frame containing wind direction, wind speed, and pollutant concentrations.

pollutant

A column name identifying a pollutant concentration.

angle

Angle of the spokes. Ideally a number by which 360 is evenly divisible (see bias_corr).

facet

One or two faceting columns. facet determines how the data are split and then plotted. When facet is length 1 it is passed to ggplot2::facet_wrap(), and when it is length 2 it is passed to ggplot2::facet_grid() with the first element being used as columns and the second rows. Some other options (e.g., multiple pollutant columns) can limit the the number of faceting columns to 1.

bias_corr

When angle does not divide exactly into 360 a bias is introduced in the frequencies when the wind direction is already supplied rounded to the nearest 10 degrees, as is often the case. For example, if angle = 22.5, N, E, S, W will include 3 wind sectors and all other angles will be two. A bias correction can made to correct for this problem. A simple method according to Applequist (2012) is used to adjust the frequencies.

breaks

The number of break points to use when binning the data, or a vector of specific break points. For example, breaks = 6 will split the legend into roughly 6 equal bins, whereas breaks = c(0, 1, 10, 100) breaks the data into four segments: <1, 1-10, 10-100, & >100.

normalise

If TRUE each wind direction segment is normalised to equal one. This is useful for showing how the concentrations (or other parameters) contribute to each wind sector when the proprtion of time the wind is from that direction is low. A line showing the probability that the wind directions is from a particular wind sector is also shown.

statistic

The statistic to be applied to each data bin in the plot. Options currently include “prop.count”, “prop.mean” and “abs.count”. The default “prop.count” sizes bins according to the proportion of the frequency of measurements. Similarly, “prop.mean” sizes bins according to their relative contribution to the mean. “abs.count” provides the absolute count of measurements in each bin.

width

Width of each bar as a fraction of its maximum width. width = 1 makes all bars meet at their edges and width = 0 makes them disappear entirely. Defaults to 0.9.

border_colour

Border colour for shaded areas. Default is no border.

alpha

The transparency of the plot. This is mainly useful to overlay it on a map.

See also

annotate_rose_text() for adding an annotation of mean and calm conditions to the figure.

Other polar directional analysis functions: polar_annulus(), polar_cluster(), polar_diff(), polar_freq(), polar_plot(), rose_metbias(), rose_percentile(), rose_wind()