Tag Info

New answers tagged

0

Here's an arcpy solution. Run it within the ArcMap Python window. You need to change the three variables at the top (counties, hospitals, and field) to match your data. The output is an in-memory copy of the counties layer called Counties_output with all the fields from the hospital layer joined to it for the maximum value. If there are multiple occurrences ...


1

Note: Edited answer based on additional info provided by OP Try the following: 1) Combine the county and hospitals datasets, either via a spatial join or with identify (I personally prefer identify so I have a new layer to work with, but either should work). This should give you a single point dataset with all your hospital info, but with the addition of ...


1

SELECT ST_X(pts.geom) as lon, ST_Y(pts.geom) as lat, poly.attribute FROM points pts, polygons poly WHERE ST_Intersects(poly.geom, pts.geom); where it is assumed that the attribute you want from the polgons table is called attribute. For non-trivial table sizes, you will want a spatial index on the geometry columns of polygons/points tables.


1

Select points.*, polygons.* from points inner join polygons on st_intersects(points.geom,polygons.geom);


1

You could use a spatial database (like PostGIS). First, you put all your addresses in a table "addresses" with a column "Point" of type Point and a column "Address". CREATE TABLE addresses (Point Point, Address Varchar(50)); Then you put your polygon in another table, let's call it "poly". It can have a column "Polygon" of type Polygon and another column ...


0

In Postgis you can accomplish this by using the ST_MakeLine function. There is even an example there of this exact problem, building a line from GPS tracks. In your case, you will want to also include the ST_Intersects function, so that you only use those points that are inside you red box (aoi). SELECT gps.gps_track, ST_MakeLine(gps.geom ORDER BY ...


0

Per this left joins are not supported in GiST indices. May I recommend: SELECT grid.gid, SUM(CASE WHEN st_contains(grid.geom,kioskdhd3.geom) THEN 1 ELSE 0 END) AS total FROM grid, kioskdhd3 GROUP BY grid.gid;



Top 50 recent answers are included