Hi Michael,
I tried to play with the streets and transform them into a
spatialLines by:
l1=split(Snow.streets[,3:4],as.factor(Snow.streets[,1]))
Ll1=lapply(l1,Line)
Lsl1=Lines(Ll1,paste("Street",1:length(Ll1)))
Snow.streets.sp=SpatialLines(list(Lsl1))
plot(Snow.streets.sp)
For the pumps:
spp=SpatialPoints(Snow.pumps[,3:4])
Snow.pumps.sp=SpatialPointsDataFrame(spp,Snow.pumps[,1:2])
plot(Snow.pumps.sp,add=T,col='red',pch=20)
For the deaths:
Snow.death.sp = SpatialPoints(Snow.deaths[,2:3])
plot(Snow.death.sp,add= T, col ='blue')
For polygons, I think that it should be a little bit more
complicated.. but I have no time today to have a look at it.
Is it correct Roger?
Cheers.
Roger Bivand wrote:
On Fri, 30 Oct 2009, Michael Friendly wrote:
Hi
In a new package, HistData, on R-Forge, I have a collection of
historical data sets, some map-related,
including the map and data related to John Snow's famous map of the
1854 cholera outbreak in London.
https://r-forge.r-project.org/projects/histdata/
I have two examples in example(Snow) that re-create the map of
deaths, one showing Theissen polygon
boundaries around the water pumps, the other showing bivariate
density contours, but they are entirely
done using base graphics and ordinary data frames. I'm wondering if
anyone is willing to help me show
a more sp-ish way to organize the data and map info and make these
and other plots.
More generally, I would welcome any other contributions to this
project.
Michael,
This is good news. I'm sorry that I didn't respond to your message
about the Guerry dataset from almost two weeks ago, I ought to have
done. I'll try to get back to you on both that question:
https://stat.ethz.ch/pipermail/r-sig-geo/2009-October/006673.html
and this one. I encourage others to join in, because the R-forge
package has the potential to become a valuable resource.
Best wishes,
Roger