[R] pie chart in lattice - trellis class

Ben Bolker bolker at zoo.ufl.edu
Mon May 28 14:50:33 CEST 2007

> Yes indeed. Thats' likely what I am going to do. Anyway, to plot axes, 
> labels of sophisticated graphs on maps may be interesting anyway. For 
> instance, we are monitoring fox and hare populations in tens of game 
> areas. Drawing observations (panel.xyplot) over time and representing 
> the trend variations (panel.loess) at the very place on the map where 
> the observations were done gives an absolutely interesting view where 
> spatial relationships between trends can be visualized.
> Patrick

  There is a floating.pie in the plotrix package, and a hidden
floating.pie.asp function in the ape package.  I agree that grid
objects would be a more elegant way to implement these ...
(The standard argument is that "thermometers" or mini-barplots
would be a better way to view this information, but I agree that
pie charts seem familiar to people.)  I have the feeling that I've
seen pie-charts-on-maps somewhere ... searching the R Graphics Gallery
for "pie" also produces the "hexbin pie" plot (which doesn't
use grid either ...)

  Ben Bolker

More information about the R-help mailing list