Skip to content

Windrose Percent Interval Frequencies Are Non Linear! Help!

3 messages · Brittain Briber, Ben Bolker, Peter Ehlers

#
Brittain Briber <brittbriber <at> yahoo.com> writes:
The "Details" of ?windrose in circular says
quite explicitly that it preserves the areas of "pedals" [sic],
so it's unlikely that this is adjustable without hacking the
code. (Hmmm, maybe I will write to the maintainers and ask
them to correct the spelling of "petals" throughout ...)

  On the other hand, there are a *lot* of alternative windrose/circular
histogram-plotting functions out there in CRAN-contrib-land.
library("sos"); findFn("wind rose") finds them in packages
plotrix, openair, oce, climatol, IDPmisc, ggplot2 ... and
that's not counting rose.diag in the CircStats package.

  I would take a quick look and see if any of those packages
work for you. 

  Ben Bolker
#
On 2011-04-08 09:26, Ben Bolker wrote:
Brittain,

I think that Ben is correct: you would have to hack the code.
Here's a way around that, but it just seems to show up another
problem in windrose():

   set.seed(1)
   x <- circular(runif(100, 0, 360), units="degrees")
   y <-  rgamma(100, 15)
   DF <- data.frame(x, y)
   windrose(DF, fill.col='yellow', cir.ind=NULL)

## now superpose a set of circles
   symbols(matrix(0,5,2), circles=1:5/5, inches=FALSE,
           fg="red", add=TRUE)

There is obviously a problem with the aspect ratio and I
think it's in windrose(). Here's a more pronounced look
at the problem:

   windrose(DF, fill.col='yellow', cir.ind=NULL, bins=1)
   symbols(0, 0, circles=1, inches=FALSE,
           fg="red", add=TRUE)

You could also have a look at the draw.circle() function
in the plotrix package.

Peter Ehlers