Re: [R] Help with maps

2008-12-07 Thread zerfetzen
I'm brand new to the map function too, here's my attempt at coloring a map of the states according to a rate (rather than count): map('state')$names MyCount <- c(1:63); MyRate <- runif(63, 0, 1) map('state', fill=TRUE, col=rgb((1-MyRate),MyRate,0,1)) Seeing that there are 63 "states", means you'

Re: [R] Help with maps

2008-12-03 Thread Avram Aelony
aha!, thanks for this. Avram On Dec 2, 2008, at 5:38 PM, Ray Brownrigg wrote: On Wed, 03 Dec 2008, Ray Brownrigg wrote: The easiest way would be: map('world', regions="UK", xlim=c(-10, 5), ylim=c(48, 60)) But of course: map('world', regions=c("UK", "Ireland"), xlim=c(-10, 5), ylim=c(48,

Re: [R] Help with maps

2008-12-02 Thread Ray Brownrigg
On Wed, 03 Dec 2008, Ray Brownrigg wrote: > The easiest way would be: > map('world', regions="UK", xlim=c(-10, 5), ylim=c(48, 60)) > But of course: map('world', regions=c("UK", "Ireland"), xlim=c(-10, 5), ylim=c(48, 60)) might be more appropriate. HTH Ray Brownrigg MSCS, Victoria University of

Re: [R] Help with maps

2008-12-02 Thread Ray Brownrigg
On Wed, 03 Dec 2008, Avram Aelony wrote: > On Tuesday, December 02, 2008, at 04:40PM, "hadley wickham" <[EMAIL > PROTECTED]> wrote: > >On Tue, Dec 2, 2008 at 6:21 PM, Avram Aelony <[EMAIL PROTECTED]> wrote: > >> A few questions about maps... > >> > >> (1) How can I find a listing of the internal d

Re: [R] Help with maps

2008-12-02 Thread Avram Aelony
On Tuesday, December 02, 2008, at 04:40PM, "hadley wickham" <[EMAIL PROTECTED]> wrote: >On Tue, Dec 2, 2008 at 6:21 PM, Avram Aelony <[EMAIL PROTECTED]> wrote: >> A few questions about maps... >> >> (1) How can I find a listing of the internal data sets that map() from the >> maps library co

Re: [R] Help with maps

2008-12-02 Thread hadley wickham
On Tue, Dec 2, 2008 at 6:21 PM, Avram Aelony <[EMAIL PROTECTED]> wrote: > A few questions about maps... > > (1) How can I find a listing of the internal data sets that map() from the > maps library contains? > For example, "usa", "county", "state", "nz" all work. Are there any others? help(packa

Re: [R] help with maps : center on the dateline

2008-11-07 Thread Duncan Murdoch
On 11/7/2008 12:08 PM, [EMAIL PROTECTED] wrote: Hi, I'm trying to plot a map of the pacific ocean, centered on the dateline, using the maps package. library(maps) # Basic library to draw maps library(mapdata)# Library with specialized maps library(mapproj) map(database = "world", fill = TRUE,