I'm hoping to use R for spatial analysis. In working through examples in Chapt. 4 of Applied Spatial Data Analysis with R I've come across the following error in trying to plot lines with the meuse data set. The text is verbatim from the book.> m.sl <- SpatialLines(list(Lines(list(Line(cc)))))Error in Lines(list(Line(cc))) : Single ID required What does "Single ID required" mean? Thanks. Mark
On 26/10/2011 1:11 PM, Mark Newcomb wrote:> I'm hoping to use R for spatial analysis. In working through examples in Chapt. 4 of Applied Spatial Data Analysis with R I've come across the following error in trying to plot lines with the meuse data set. The text is verbatim from the book. > > > m.sl<- SpatialLines(list(Lines(list(Line(cc))))) > Error in Lines(list(Line(cc))) : Single ID required > > What does "Single ID required" mean?That message is coming from a contributed package, not from base R. You should say what package you're using, and you may need to contact the author or maintainer of it to get an answer. Duncan Murdoch
Mark Newcomb <newc1.mac <at> me.com> writes:> > I'm hoping to use R for spatial analysis. In working through examples inChapt. 4 of Applied Spatial Data> Analysis with R I've come across the following error in trying to plot lineswith the meuse data set. The> text is verbatim from the book.This is in Chapter 3, and is mentioned in the errata on the book website, http://www.asdar-book.org. The code download is also updated on the website. The erratum is: Chapter 3 Page 59: Top of page - from sp version 0.9-66, Lines objects must be give a valid ID; changed to m.sl <- SpatialLines(list(Lines(list(Line(cc)), "1"))). Lines and Polygons objects must have valid IDs. As mentioned in another reply, the R-sig-geo list may be more relevant for a question of this kind. Hope this clarifies, Roger> > > m.sl <- SpatialLines(list(Lines(list(Line(cc))))) > Error in Lines(list(Line(cc))) : Single ID required > > What does "Single ID required" mean? > > Thanks. > > Mark > >