Plots a rose diagram (rose of directions), the analogue of a histogram or density plot for angular data.
## S3 method for class 'default': rose(x, breaks = NULL, \dots, weights=NULL, nclass = NULL, unit = c("degree", "radian"), start=0, clockwise=FALSE, main)
## S3 method for class 'histogram': rose(x, \dots, unit = c("degree", "radian"), start=0, clockwise=FALSE, main, labels=TRUE, at=NULL, do.plot = TRUE)
## S3 method for class 'density': rose(x, \dots, unit = c("degree", "radian"), start=0, clockwise=FALSE, main, labels=TRUE, at=NULL, do.plot = TRUE)
## S3 method for class 'fv': rose(x, \dots, unit = c("degree", "radian"), start=0, clockwise=FALSE, main, labels=TRUE, at=NULL, do.plot = TRUE)
- Data to be plotted.
A numeric vector containing angles,
histogramobject containing a histogram of angular values, or a
densityobject containing a smooth density estimate for angular data, or an
- breaks, nclass
- Arguments passed to
histto determine the histogram breakpoints.
- Additional arguments passed to
polygoncontrolling the appearance of the plot (or passed from
- The unit in which the angles are expressed.
- The starting direction for measurement of angles,
that is, the spatial direction which corresponds to a measured angle
of zero. Either a character string giving a compass direction
- Logical value indicating whether angles increase in the clockwise
clockwise=TRUE) or anti-clockwise, counter-clockwise direction (
clockwise=FALSE, the default).
- Optional vector of numeric weights associated with
- Optional main title for the plot.
- Either a logical value indicating whether to plot labels next to the tick marks, or a vector of labels for the tick marks.
- Optional vector of angles at which tick marks should be plotted.
at=numeric(0)to suppress tick marks.
- Logical value indicating whether to really perform the plot.
A rose diagram or rose of directions is the analogue of a histogram or bar chart for data which represent angles in two dimensions. The bars of the bar chart are replaced by circular sectors in the rose diagram.
rose is generic, with a default method
for numeric data, and methods for histograms and function tables.
x is a numeric vector, it must contain angular values
in the range 0 to 360 (if
or in the range 0 to
2 * pi (if
A histogram of the data will first be computed using
hist. Then the rose diagram of this histogram
will be plotted by
x is an object of class
"histogram" produced by
hist, representing the histogram
of angular data, then the rose diagram of the densities
(rather than the counts) in this histogram object will be plotted.
x is an object of class
"density" produced by
representing a kernel smoothed density estimate of angular data,
then the rose diagram of the density estimate will be plotted.
x is a function value table (object of class
then the argument of the function will be interpreted as an angle,
and the value of the function will be interpreted as the radius.
By default, angles are interpreted using the mathematical convention
where the zero angle is the horizontal $x$ axis, and angles
increase anti-clockwise. Other conventions can be specified
using the arguments
Standard compass directions are obtained by setting
- A window (class
"owin") containing the plotted region.
ang <- runif(1000, max=360) rose(ang, col="grey") rose(ang, col="grey", start="N", clockwise=TRUE)