We’re rewarding the question askers & reputations are being recalculated! Read more.

Questions tagged [intersection]

Use this tag when asking questions related to where features overlap.

Filter by
Sorted by
Tagged with
7
votes
2answers
3k views

Clipping vs Intersecting

I was curious why clipping shapefiles was just so difficult and whether it was different to intersecting shapefiles? You will see from one my questions that I gave up trying to clip a polyline with a ...
0
votes
1answer
3k views

Creating buffers around points and merging with SpatialPolygonsDataFrame to create a list of matched polygons and area of intersection?

I have data on polling booths as points and data on village boundaries as polygons. I want to create buffers of 1km around the polling booths and (a) save the ID of all the villages that intersect ...
1
vote
0answers
37 views

Check point in line segment not accurate in Shapely

I use Shapely and I've run into an issue where I can find the intersection of two lines. However once I have the intersection point, I don't seem to be able and cross-reference that it belongs in both ...
0
votes
0answers
54 views

Using ST_Intersection with three or more tables

I'm trying to achieve a multiple-table intersect with PostGIS while retaining the geom for each shape. For any given property shape, I want individual cuts of that shape split apart by different ...
0
votes
1answer
43 views

Calculating the area of one layer inside area of another layer QGIS [duplicate]

I am currently looking at some Marine Protected Areas (MPAs) in Madagascar, and am trying to work out the percentage reef cover inside an MPA boundary. For example (in the picture below), I have the ...
19
votes
2answers
32k views

Extracting intersection areas in R

I have two polygons. One contains fields(X,Y,Z) and the other contains soil types (A,B,C,D). I want to know what area of every field contains which type of soil. I tried the following: library(rgdal)...
10
votes
1answer
5k views

Intersecting lines to get crossings using Python with QGIS?

I have a set of lines representing bus lines. Some of the lines are overlapping and take the same roads. I am able to extract the nodes. However I am interested in extracting only crossings like ...
0
votes
1answer
48 views

Intersection of two sets in openstreetmap to find parent of any area

I am trying to determine what the parent administrative area of any given area. The idea is that the closest parent is the administrative area with the highest/deepest admin_level that is shared as a ...
1
vote
1answer
125 views

How to find lat/long of point knowing cross track distance

Knowing lat/long of point A , B and C. And knowing cross track distance (CTX) from point B to point D. How to find lat/long of point D?
9
votes
4answers
7k views

Distinguishing lines that intersect from lines that touch?

How do I distinguish between these cases in ArcGIS 10? Case 1: Both endpoints of a line touch another line Case 2: Both endpoints dangle over the lines it intersects I am looking at the Trim Line ...
2
votes
3answers
793 views

Determining if polygon lies completly in another polygon or only partly using QGIS? [closed]

I primarily use QGIS. I have two Layers which both contain polygons.So one layer(A) contains only one polygon, the other contains a number of polygons(layer (B)). I can run the Intersect-Tool and ...
2
votes
2answers
135 views

What is the proper name for the “Venn diagram” of a set of geometries?

Sometimes, you have a set of overlapping geometries, and you want to generate an output like this: Image taken from this answer. The resulting polygons have no overlaps; each region of space is ...
1
vote
0answers
45 views

Selecting only coinciding points

I have a lot of points in the same layer. Many of these are coinciding. I only want the points that coincide slected or the points that don't coincide (then I can just reverse the selection). This is ...
3
votes
1answer
184 views

Use intersection in field calculator

I want to use the tool intersects in the field calculator. If the condition is true, I want to set a result field to a specific number. The field calculator doesn't accept my expression but I can not ...
2
votes
1answer
2k views

Fast intersection of a list of polygons with a bounding polygon using Shapely

I have a list of Shapely polygons which I need to find the intersection of each with a bounding Shapely polygon. Not all the polygons in the list cross the boundary of the bounding polygon so I only ...
2
votes
1answer
79 views

Getting the percentage area of intersecting polygons [closed]

I have the polygons for census tracts within New York City. I also have the polygons for the parks. What I would like is % of the census tract area, with an added 400 meter buffer, that is park. I'm ...
1
vote
0answers
98 views

Python script creation, intersection Points and polygons [closed]

I have these two shapefiles, one with polygon geometry and the other with point geometry, that I am working on in QGIS. I want to create a script using Python to see the intersection of points and ...
2
votes
1answer
60 views

return only one value per point from ST_Value() - currently returning 2 values for some points

I'm testing a point sample query with a subset of 5 points on a single band elevation raster. Using my usual approach (which I've previously not noticed this behavior), I get six records returned: ...
17
votes
1answer
6k views

Finding Nearest Line Segments to Point using shapely?

Background From a known Point, I require to establish the nearest surrounding "visible perimeter" against a table of MultiLineStrings, as shown on the diagram. I've searched this site with a number ...
2
votes
1answer
51 views

Check 2 Extents with Disjoint in Arcpy - Wrong Result

I'm now facing a problem using Disjoint in Arcpy to check if 2 extents are intersected. I have 2 extents like this: Ext1: 33206887.500051 5890587.49999999 33460887.500051 6060887.49999999 NaN NaN ...
0
votes
0answers
16 views

Adding vertices to polyline [duplicate]

I have a polyline shapefile with multiple features. I also have a point shapefile containing only points that are on the lines. What I'm trying to do is to add a new vertex to every line where it ...
2
votes
0answers
108 views

T-SQL Invalid Geometry Created by Intersection

I have two sets of geometries (A and B) in SQL Server 2016. I want to determine the overlap areas of those geometries from set A that intersect set B. Most of the time this code works: SELECT a....
4
votes
1answer
335 views

Creating cluster of crashes using QGIS?

I have a shapefile with 52K points of road accidents, between 2007 and 2012. Each accident has a severity index. I want show clusters of 5 accidents (at least), for each year, that have a severity ...
0
votes
0answers
191 views

How to update column based on data from another table (Mapinfo Pro)?

What I want to do is update column (Table A) by values from another table (Table B) using condition intersects. There are few objects in table B which intersects one object from table A. When I try to ...
1
vote
1answer
99 views

Styling road intersections

I have two layers with roads of different types I wish to have pretty intersections, as here Symbol levels work only for features in single layer.
-2
votes
1answer
40 views

Filter four features from a vector shapefile to create a new layer to perform buffer, intersection and union on it, in QGIS 2.18?

From a dataset that contains points of interest defined by type of object with four different features, I am trying to distinguish the features to perform different analysis. Thought I had to filter ...
1
vote
0answers
63 views

Analyzing single Polygon or Polyline that overlaps itself using ArcObjects?

My current process is to determine obstructions in an area and determine properties of those obstructions as they relate to a centre polyline. Per the image below I take a polyline which denotes a ...
5
votes
1answer
3k views

Iterating over several layers and running process using PyQGIS?

I am trying to find road intersections within each of my memory Polyline layers (which are named road_layer_i for i in (0-99)) so this is what I tried: import processing self=qgis.utils layers = ...
0
votes
1answer
1k views

Writing Python code to create intersection loop with geodatabase? [closed]

I am trying create a loop that will intersect each individual township with a statewide section layer. I am having trouble with the syntax of the intersect tool I think, but maybe it is something else....
0
votes
1answer
58 views

How to snap to intersection of lines with Classic snapping?

The question is as simple as the title. When I am in Edit session with Classic Snapping enabled and want to snap to an intersection of lines, it does not work. In order to achieve this, I have to ...
6
votes
2answers
3k views

How to split a polygon using R

I have an irregular polygon which is a spatial object. I want to divide it into multiple polygons (say, n=25) with equal height. To show how I want to divide it, I've plotted grids on the background ...
0
votes
1answer
268 views

Intersect of raster image on Google Earth Engine

I have this situation on Google Earth Engine: 3 different images, each of these are made by 17 different bands. These bands represent the different year. I call these images with these letter: a,b ...
3
votes
0answers
100 views

Unable to compute intersection between two polygons using PyQGIS?

I have two polygons in different layers. I am trying to find the intersect between the two polygons. Below a figure showing my test case. I initially wanted to find the intersect between the green ...
3
votes
0answers
90 views

Intersection and area calculations in geographic vs. projected coordinates

I think one should do intersection calculations when layers are in the same coordinate system, and one should do area calculations in the appropriate projected coordinate system. The order matters, ...
1
vote
0answers
15 views

Deleting vector layer within buffer? [closed]

I am trying to delete points from a shapefile with vector information that intersect a buffer that was created. I have tried using the intersect tool, but that only highlights the information that ...
0
votes
2answers
371 views

Faster alternative to `Intersection` in QGIS to just retain overlapping features without cutting

I want to keep only the features from my data layer (polygon A) within my area of interest (AOI). If I compare two methods to perform that, the processing time is very different. Intersection tool I ...
0
votes
2answers
468 views

Extracting data from four intersecting polygon layers in PostGIS?

I've been using the following code in PostgreSQL/PostGIS for the last year, as needed, which is about once a quarter. It works OK, it's just that it takes days to run. With over 25,000 parcels making ...
1
vote
1answer
96 views

Why does shapely intersection of two lines change behaviour when fiona module is imported?

I am having issues with calculating an intersection of two LineStrings using Shapely. Such an intersection should return a point, yet my code returns a LineString. I found a simple example of an ...
1
vote
0answers
99 views

Query for finding intersection points between adjacent features within a buffer tolerance - PostGIS

I've developed the queries to find out intersection points (within 0.2 buffer) between line and polygon and also within adjacent polygons by using PostgreSQL 10 and PostGIS 2.4 database. Line data is ...
0
votes
1answer
2k views

turfjs intersect line and polygon

In old turfjs versions, it was possible to intersect a line and a polygon, like in this example. But changing the turf.js version to the last one makes it fail, as shown in this other example. The ...
1
vote
0answers
38 views

How to output file with all overlaps between two Shapefiles - Neighborhood/Zip Codes [closed]

I have a pretty specific problem I would like help with. I have two shapefiles: neighborhoods from https://www.zillow.com/howto/api/neighborhood-boundaries.htm zip codes from the census bureau: ...
1
vote
0answers
353 views

Comparing speed of Spatial Analysis with GeoJSON versus shapefile in QGIS?

I have a large dataset that I want to perform spatial analysis on in QGIS. Specifically, I want to perform a polygon intersection analysis between two polygon layers. Given the size of the dataset ...
1
vote
1answer
267 views

How to find intersection polygons in single layer on QGIS version 3.4.2?

I have polygons intersection in single layer. I want polygon in yellow frame and use polygon intersection to calculate area , how to do this?
9
votes
2answers
5k views

Removing intersect of one polygon from another using R?

I am trying to remove the intersect from Poly2 onto Poly1. Below are the coords of the 2 polygons. > coords1 [,1] [,2] [1,] 992.0161 7462.531 [2,] 950.1962 7413.532 [3,] 902.3632 ...
1
vote
1answer
86 views

PostGIS ST_Intersects result is ignored by where condition

I have a simple query filtering by st_intersects function finding all lines intersecting with a polygon. select *, st_intersect(graph_line, st_geomfromtext('POLYGON((261 156,148 452,333 507,566 199,...
3
votes
1answer
142 views

Extending a segment in QGIS to check intersection with a polygon

I am trying to find the adress points (red dots) located in front of an obstacle (red polygon). The street is green and the pink line represents the street face (Si). This is what I have so far, but ...
0
votes
0answers
352 views

Geopandas KeyError: “['__idx1' '__idx2'] not found in axis” during overlay operation

I'm trying to get the intersection area between two geodataframes using the overlay method. gpd_df1 = gpd.read_file("shapefile1.shp") ## US census tract shape file gpd_df1 = process(gpd_df1) ## ...
1
vote
1answer
116 views

No output of simple intersection in QGIS / Shapely

I have three simple geometries (download): 1) Province boundaries of a province in Egypt (Al Wadi Al Jadid). 2) A 10 x 10 degree polygon (index = 417). 3) another 10 x 10 degree polygon (index = 416)....
2
votes
0answers
190 views

Is PostGIS faster than Shapely [closed]

I've recently tried using Shapely to dissolve and intersect large sets of 100'000+ geometries, some of them quite complex. This would take me at least one hour, at which point I would usually shut the ...
2
votes
1answer
97 views

Intersection of touching geometries returns a polygon

I'm using Postgis 2.3. I have two touching geometries that I got from an overlay (ST_Difference) operation: id | st_astext 3 | MULTIPOLYGON(((0 -2,0 ...