[R] legend in bubble plots made with symbols()

Roger Bivand Roger.Bivand at nhh.no
Sat Mar 18 21:49:15 CET 2006


On Sat, 18 Mar 2006, Denis Chabot wrote:

> Hi,
> 
> I have read about the use of symbols() to draw circles of different  
> sizes, but I have not been able to find out how to add a legend to  
> such a graph, legend that would display some specific sizes and their  
> meaning.
> 
> Before finding the symbols function in Paul Murrell's book, I had  
> rolled by own function where the variable I want to use to control  
> circle size was actually used to control cex. I was able to draw a  
> legend afterward. Symbols seems a bit simpler and I wanted to see if  
> it would be better than my own function. But without legend it is  
> less useful. However I'm sure there is a way which I'm not aware of  
> to draw a legend for a plot drawn with symbols()...
> 

There is a recent paper in JSS by Susumu Tanimura, Chusi Kuroiwa, and 
Tsutomu Mizota, including some legend code:

http://www.jstatsoft.org/

Volume 15, 2006, Issue 5

> Thanks in advance,
> 
> Denis Chabot
> 
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
> 

-- 
Roger Bivand
Economic Geography Section, Department of Economics, Norwegian School of
Economics and Business Administration, Helleveien 30, N-5045 Bergen,
Norway. voice: +47 55 95 93 55; fax +47 55 95 95 43
e-mail: Roger.Bivand at nhh.no




More information about the R-help mailing list