[R-sig-Geo] Error in spCbind(GA0, data) : row names not identical

Marvin Sharma marvinsharma at yahoo.com
Sun Oct 22 14:48:20 CEST 2017


HI,Could some one help  this newbie in fixing the spCbind problem encountered below?>names(data) "county"    "y"         "x"         "Latitude"  "Longitude"
GA <- map("county", "georgia", plot=FALSE, fill=TRUE)
cntys <- tolower(as.character(data$county))GA$names <- substring(GA$names, 9, nchar(GA$names))match(cntys, GA$names)##It does  match!#######################################GA <- map2SpatialPolygons(GA, GA$names)proj4string(GA) <- CRS("+proj=longlat")row.names(data) <- cntysGA0 <- SpatialPolygonsDataFrame(GA, data=data.frame(ID=1:159,row.names=row.names(GA)))GA1 <- spCbind(GA0, data)> GA1 <- spCbind(GA0, data)Error in spCbind(GA0, data) : row names not identical> Thanks n advance,
Marvin
	[[alternative HTML version deleted]]



More information about the R-sig-Geo mailing list