Yes! I would have thought on that if spol where a spatialpolygonsDataFrame, (as many sp functions for SpPolDF actually mimic functions for dataframes, which is great help for the memory), but in this case, spol is just a spatialpolygons and the user probably will not think at that.
Thanks! Agus 2010/5/20 Roger Bivand <roger.biv...@nhh.no>: > On Thu, 20 May 2010, Agustin Lobo wrote: > >> Is there a cleaner way to check all IDs of a spatialPolygons object? >> I know how to do it with one: >> > slot(s...@polygons[[2]],"ID") >> [1] "g2" >> >> and for all of them I use >>> >>> sapply(s...@polygons,slot,"ID") >> >> is there something more straightforward, sort of spFIDs() (by analogy >> to spChFIDs() )? > > row.names(spol), OK? > > Roger > >> >> Thanks >> >> Agus >> >> _______________________________________________ >> R-sig-Geo mailing list >> R-sig-Geo@stat.math.ethz.ch >> https://stat.ethz.ch/mailman/listinfo/r-sig-geo >> > > -- > 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.biv...@nhh.no > > _______________________________________________ R-sig-Geo mailing list R-sig-Geo@stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo