xoa.core.plot.plot_rose#
- xoa.core.plot.plot_rose(direction, value, nsector=16, edges=None, rose=None, **kwargs)[source]#
Plot a rose of the frequencies of a direction and a value
- Parameters:
direction (array_like) – Directions in degrees, clockwise from the north. Waves and winds usually come from a direction and currents go to it: this does not change the plot.
value (array_like) – Values, like speeds or heights, with the same size as the directions
nsector (int) – Number of sectors, centered on the north
edges (None, array_like) – Lower edges of the bins of value, see
xoa.core.stats.rose_hist()rose (None, Rose) – Existing rose. It is created when not provided.
kwargs – Parameters of
Rosewhen it is created, or ofRose.add_bars(), likecmap,colorsandlabel.
- Returns:
Rose – The rose, which holds the axes in its
axattribute and the plotted artists
Example
plot_rose(wdir, wspd, edges=[0, 5, 10, 15, 20], label="Wind speed [m/s]")