On a map, a closed shape defined by a connected sequence of x,y coordinate pairs, where the first and last coordinate pair are the same and all other pairs are unique.

learn more… | top users | synonyms

21
votes
7answers
15k views

Removing small spaces (slivers) between polygons?

I have a set of polygons representing administrative districts. The districts were digitized by hand, and there are small spaces (slivers) between polygons where the polygons should be touching. How ...
20
votes
3answers
3k views

How can I calculate the average width of a polygon?

I'm interested in examining the average width of a polygon that represents the road surface. I also have the road centerline as a vector (which is sometimes not exactly in the center). In this example ...
19
votes
3answers
1k views

Packing Polygons within polygon

I have a Boolean raster. In the grey areas of the raster I would like to fit a given size polygon within a contiguous extent. Basically, I have an irregular polygon, and i would like to "fit" a ...
17
votes
4answers
5k views

Separate polygons based on intersection using PostGIS

I have a PostGIS table of polygons where some intersect with one another. This is what I'm trying to do: For a given polygon selected by id, give me all of the polygons that intersect. Basically, ...
16
votes
4answers
853 views

What are the benefits of hexagonal sampling polygons?

I am always on the lookout for useful methods to sample or partition study areas (usually in the form of raster datasets) into smaller units. Recently, I read an ESRI blog post about a new tool for ...
16
votes
2answers
4k views

How can I find a point inside a polygon in PostGIS?

How can I find a point that is guaranteed to be within a given polygon in PostGIS? I am aware of the ST_Centroid function. However, the centroid is not always within a polygon, see below: ...
15
votes
5answers
1k views

Algorithm to fix topological errors in GIS software apps

Related question here. I notice that ensuring topological correctness is essential for GIS applications, this is because the input from user or polygon boolean operation can have severe topological ...
14
votes
6answers
4k views

Generate points that lie inside polygon

I have polygon feature and want to be able to generate points inside it. I need this for one classification task. Generating random points until one is inside the polygon wouldn't work because it's ...
14
votes
4answers
2k views

What is the best open-source web mapping solution for handling 3000+ polygons

I have 3000+ polygons which represent watersheds (18 main watersheds). At the first stage all the 18 watershed will show and their list will be placed in the left sidebar. If any user mouse over the ...
14
votes
2answers
2k views

Is it possible to gray out a Google Maps map except for some area?

What i am looking for is a way to emphasize a certain area on a Google Maps map by graying out the rest of the world. I heard about some solution of using 2 polygons of which 1 is visible and the ...
14
votes
3answers
1k views

How to find the maximum-area-rectangle inside a convex polygon?

In this post we are looking for algorithms / ideas on how to find the maximum-area-rectangle inside a convex polygon. In the following figure, numbers are the areas of the fitted rectangles. As shown ...
13
votes
4answers
675 views

Why do valid polygons repeat the same start and end point?

In the GIS world, for most modern formats and Standards (e.g., Shapefiles, WKB/WKT, GML, KML, etc.), valid polygons need to have closed linear rings, which is a linestring of coordinates where the ...
13
votes
6answers
6k views

How to use ST_Intersection?

Here's a quick summary about what I'm trying to do: I have 3 tables in Postgres, 'a' and 'b', each have a Polygon column, and 'c' has a Point column. What I'm trying to do here is to get the ...
13
votes
2answers
1k views

Creating Thiessen (Voronoi) polygons using lines (rather than points) as the input features?

I have a set of line features inside a particular polygonal boundary. For each line, I'd like to generate a polygon inside which every possible point is closer to the given line than to any other line ...
13
votes
2answers
2k views

How can I fix my complex Polygons so they show correctly in Google Maps?

Problem: I'm trying to find a way to fix some broken polygon shapes and I'm not sure how I can do this. Details: I've got a number of polygons which I basically imported from TIGERLINES a while ...
12
votes
4answers
15k views

Extract coordinates of polygon vertices in ArcMap 10?

I've got about a dozen polygons in a feature class loaded in ArcMap 10, all in geographic WGS 1984. How do I easily obtain the coordinates associated with each vertex of each polygon in that feature ...
11
votes
5answers
3k views

Get Raster Values from a Polygon Overlay in Opensource GIS Solutions

I have two layers. A polygon-shape-layer with many tiles and a raster-layer containing CORINE 2006 land cover with many categories in a colourmap. I want to obtain for each polygon in the shapelayer a ...
11
votes
3answers
3k views

How to merge two Polygons in OpenLayers?

I have two polygons. polygon1 = new OpenLayers.Feature.Vector(new OpenLayers.Geometry.Polygon([linearRing1])) polygon2 = new OpenLayers.Feature.Vector(new OpenLayers.Geometry.Polygon([linearRing2])) ...
11
votes
3answers
2k views

Optimizing a nearest neighbor calculation using PostGIS

I'm using PostGIS to calculate the nearest neighbors of polygons. What I want to calculate is the minimum distance from each polygon, to the nearest polygon. Thus far I have got great help from Mike ...
11
votes
3answers
310 views

How to improve drawn shapes in Quantum-GIS?

I have a polygon-shape in qgis-1.7.0 and want to fix overlays and gaps between the edges of adjacent polygons. See image below. Is there any automated way to do this in quantum-gis? Or any other ...
11
votes
4answers
1k views

How to colour polygons with a completely transparent fill using MapServer?

Is it possible to fill polygons so that they are completely transparent in MapServer? I want to have a black background that is slightly opaque, and wherever there is a polygon I want that to be ...
11
votes
4answers
1k views

ArcGIS - How do I group corner-touching contiguous polygons?

Using ArcGIS 10, I have a Feature Class which I converted from a Raster (GRID) (Raster To Polygon Tool). There are approx. 180,000 polygons. The attribute table contains a [grid_code] field which ...
11
votes
3answers
1k views

Self intersections for polygons, how to solve?

I have a question about repairing a self intersecting polygon shapefile. I have a shapefile containing Polygons (ZM) which have self intersecting features. If I use the "repair geometry" tool, it ...
10
votes
6answers
1k views

How do I make a heat or Choropleth map that uses polygons in QGis?

I've been playing around with the heatmap plugin for QGIS and I am wondering if it is possible to make heatmap with using a similar plugin/tool that uses polygons as well as points? I would like to ...
10
votes
6answers
3k views

How to find the boundary co-ordinates from a given set of co-ordinates

Given a set of coordinates, How do we find the boundary coordinates. <== Figure 1 Given the coordinates in the above set, How can I get the coordinates on the red boundary. Boundary is the polygon ...
10
votes
3answers
4k views

How to merge two 'incompatible' polygon layers in ArcGIS?

I have two layers of polygons with administrative boundaries. Although they come from the same data provider, they seem to have small discrepancies and do not 'fit' each other. How could I merge ...
10
votes
5answers
4k views

How best to fix a non-noded intersection problem in PostGIS?

I'm using a PL/R function and PostGIS to generate voronoi polygons around a set of points. The function that I am using is defined here. When I use this function on a particular dataset I get the ...
10
votes
1answer
522 views

How to convert fake donut holes in polygons to real ones?

I have this problem where I have to import shapefiles into our system which must be geometrically valid, but the software that everyone uses to produce them seems to output files where every polygon ...
10
votes
3answers
793 views

Polygons from Polylines in either ArcView or FOSS

I have 20,000 polylines in a .gdb that represent about 5,000 building footprints. Some of the building footprints have pretty substantial gaps (image below). I would like to snap the polylines closed ...
10
votes
2answers
2k views

Intersecting a raster with a polygon using PostGIS - artefact error

I'm using PostGIS2.0 to do some raster/polygon intersections. I'm having difficulty understanding which operation I should use, and what the quickest way of performing this is. My problem is as ...
9
votes
3answers
13k views

How to convert .shp to .csv including attributes AND geometry?

I have a .shp file with 60k+ entries, all of which are polygons with corresponding attributes (acreage totals, landowner names, tax ID #s, etc.). What I ultimately need is a .csv file with all of ...
9
votes
5answers
1k views

Where can I get neighborhood boundaries?

Besides Zillow's creative-commons licensed neighborhood boundaries shapefiles, what sources of neighborhood boundaries are there? Not just in the US, but all over the world. Free/open source is ...
9
votes
4answers
19k views

How to split a polygon into multiple equal-width polygons in ArcMap 10?

I am adding parking spaces into a parking lot, and I need them to be exactly the same shape and not overlap each other or have spaces between. In ArcMap 9.3, there was an editing task that allowed you ...
9
votes
2answers
3k views

How to check Topology in QGIS?

I have two Shapefiles with Polygons ( City and Forerst) Is there a Plugin who is able check the topology (QGIS)? Like "Knots do not overlap" or something like that? I dont want that they overlap. ...
9
votes
1answer
2k views

Instantiating spatial polygon without using a shape file in R

So, the usual way we read a shapefile in R is via the maptools package, like this: sfdata <- readShapeSpatial("/path/to/my/shapefile.shp", proj4string=CRS("+proj=longlat")) However, I have a use ...
9
votes
4answers
6k views

using shapely: translating between Polygons and MultiPolygons

[EDIT: the solution to this was simply to use OGR to read shapefiles. See geographika's example.] In an ESRI shapefile, there is no distinction between Polygons and MultiPolygons. Furthermore, there ...
9
votes
3answers
727 views

How to sum up values of neighbouring polygons?

I hope that you can help me with the following problem: I have a vector (polygon) layer. I would like to add an attribute to the layer that - for every polygon - sums the values of a specific field of ...
9
votes
2answers
926 views

PostGIS: split a polygon in a given ratio

Is there a convenient way to split a polygon into n parts, more-or-less equal in size in PostGIS?
9
votes
1answer
345 views

Efficient raster sampling of billions of polygons (bounding boxes)

How can a raster be computed efficiently (in Python), given a set consisting of billions of bounding boxes (read sequentially from a file), and given that the raster values for each cell should give ...
9
votes
1answer
362 views

Compare spatial cluster/agglomeration patterns for polygon data

I have agricultural data in form of polygons which I would like to test for spatial clusterings/spatial agglomerations. All in all I have about 40 variables which I can aggregate and standardize in ...
8
votes
5answers
1k views

Performing a reverse clip in ArcMap?

Is there a way to perform a 'reverse' of the clip function in ArcMap, I'm not exactly sure how to explain this so here's a diagram:
8
votes
7answers
11k views

Get boundary of raster image as polygon in ArcGIS 10

I have a rectangular raster image in ArcGIS. My question is: how can I produce a polygon which is just the extent of the raster image? That is, I want to have a polygon layer with a single ...
8
votes
4answers
3k views

How to find the minimum edge to edge distance of polygons?

I have a a map of about 3000 polygons in ArcGIS 10. I'm looking to find the distance between each one of them. I know how to do it using the lat and long coordinates of the centroid, but I'm looking ...
8
votes
4answers
3k views

Best way to delete selected mass amounts of old data from a polygon shapefile attribute table?

Dumb problem that for some reason is giving me trouble. I have a polygon shapefile that is loaded with old demographic data in its attribute file, I just received the new data today in xls format. ...
8
votes
2answers
651 views

Splitting polylines using regions with PostGIS

I was wondering if it is possible to split a polyline on polygon boundaries (regions) in PostGIS, the picture below is of what we have at the moment and showing where I need the polylines split: ...
8
votes
2answers
256 views

Creating an “average” polygon

I found this thread in the old ESRI forums with the same type of problem I am facing today. The solution to the problem is explained in little detail and since I am not an expert, I was wondering if ...
8
votes
2answers
301 views

Simple way to detect/select border polygons of a shapefile

I am looking for a simple way to detect/select border polygons of a shapefile. Border polygons are here polygons that are not completely surrounded by other polygons i.e. polygons located at the ...
8
votes
1answer
248 views

How to automatically reduce polygon size?

I am working with two polygon layers (counties & states) which I will 'intersect' to find which counties are within which states. Due to data inaccuracies I have to change all county polygons and ...
8
votes
1answer
852 views

Splitting landcover polygons (parcels) into equal sizes, while retaining road access for all?

I would like to split landcover polygons which surround a road polygon into equal sizes, while ALL resulting polygons should have access to the road! Is there any chance to do this automatically? ...
8
votes
3answers
391 views

Find Duplicate Polygons Algorithm

I have a group of polygons. My objective is to find the duplicate polygons from these group of polygons. Using NetTopologySuite(A c# port of JTS), it is possible to compare two geometires and check ...