[R] Do you know if you can map a large minmum spanning tree in R?

Michael Sumner mdsumner at utas.edu.au
Thu Aug 19 02:18:22 CEST 2004


At 09:47 AM 8/19/2004, Briggs, Meredith M wrote:



>         Do you know if you can map in R?
>         I have my minimum spanning tree, but as there are 1371 nodes (all 
> over Australia) I'd like to be able to "graph" them as they actually 
> would be on the map.
>Do you know if this is possible?

You can certainly "map" in R.  Depending on the coordinate system of your 
data . . .
but, e.g. - if it's lat/lon - perhaps the easiest way is to install the 
"maps" package and you can add the continental outlines to an existing plot:

## display nodes code here . . .
library(maps)
map('world',add=T,xlim=c(109,157),ylim=c(-47,-7))

There are plenty of other options, if you have your own map data (or want 
to use another source).  Feel free to provide more detail about your 
current plotting methods and coordinate system.

Also, the package "mapdata" contains a high resolution continental dataset 
-"worldHires"

Hope that helps, Mike.





###############################################

Michael Sumner - PhD. candidate
Maths and Physics (ACE CRC & IASOS) and Zoology (AWRU)
University of Tasmania
Private Bag 77, Hobart, Tas 7001, Australia
Phone: 6226 1752




More information about the R-help mailing list