Hey All,

I have this problem and I need really help to understand (my limit) . I have
a polygon shape file and I need to calculate some index and select the
polygon with correct index value. I DID this with library(PBSmapping), but I
need to obtain new polygon shapefile

singleGap <- readOGR(".", "singleGap")
# Convert the SpatialPolygonDataFrame into a PolySet object for
compatibility
# with the so that PBSMapping package's geospatial functions

singleGapPBS <- SpatialPolygons2PolySet(singleGap)
# Calcula AREA
singleGap.area <- calcArea(singleGapPBS)
str(singleGap.area)

# Calcula PERIMETER
singleGap.perimeter <- calcLength(singleGapPBS)
str(singleGap.perimeter)

singleGap.Index <-
data.frame(singleGap.area[,c(1,3)],singleGap.perimeter[,3])
names(singleGap.Index)[3] = "perimeter"
str(singleGap.Index)

singleGap.Index <- singleGap.Index[singleGap.Index$area >= 5
|singleGap.Index$area < 1000,]
NOW I TRYING SEVERAL METHOD BUT NOTHING. Thank, really thanks

Gianni

	[[alternative HTML version deleted]]

