Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I know nothing about GIS, but I have what I think is a GIS problem. From spending a few hours googling my problem, I think what I need to do is perform a spatial query, but I'm not sure how to go about it.

Essentially, I have some crime data (a list of specific incidents, the time date that they occurred and the address where they occurred) that I'd like to look at in relation to one particular neighborhood. I have an outline of the neighborhood on a map, which is specific enough that I could translate it into a polygon that describes the outline of the neighborhood. I'd like to filter the crime data I have to see which specific incidents happened within the bounds of this neighborhood. I think this is a spatial query, but I'm not sure.

I'm looking for some guidance on the problem in general. It appears that there are some free tools online for these kinds of things (Google Fusion Tables?) and I have access to ArcGIS and MS SQL Server. I'm familiar with SQL Server, but not ArcGIS and it doesn't look like something I could pick up and learn in a day or two, but I'm not sure.

Again, any guidance, no matter how general or specific, is appreciated.

Thanks!

share|improve this question
    
Do you want to do Spatial Queries on the Desktop (ArcGIS) or on a web page (using Google Fusion Tables)? –  Mapperz May 6 '11 at 13:57
    
check out Spatial Key spatialkey.com –  user3973 Aug 18 '11 at 0:53
    
Please explain why this product is worth looking at and deserves to be considered a solution to the question. –  whuber Aug 18 '11 at 1:37
add comment

4 Answers 4

up vote 7 down vote accepted

In ArcMap, If you look up Search in Polygon in ArcMap, you'll find this:

"Select By Location to select those features from the points layer that intersect the polygon layer"

That's found by "Selection>Select by Location" on the menu bar and it will ask for a Target layer then a Source layer and a selection method.

So the Target layer is your point layer, the Source layer the polygon layer and 'Target layer are within source layer as your spatial selection method.

Then save the output

Hope that works for you

share|improve this answer
    
Sounds like a good idea, I put in a request to have ArcGIS installed on my desktop, I'll give this a shot as soon as I can. Thanks. –  Elbelcho May 6 '11 at 13:47
    
After the ArcGIS stage you could even just export to Excel to filter the data. –  Matthew Snape May 6 '11 at 14:12
1  
If you don't already have the points on the map you will need to geocode them first, to get a coordinate for the address. –  Brad Nesom May 6 '11 at 15:52
    
To follow up: I used this method and it worked great. I had a hard time figuring out a few intermediate steps, like drawing the outline of the neighborhood on a sat view, converting that drawing to a feature and then geocoding the addresses, but once that was handled, "Select By Location" was exactly what I needed and resulted in an easy to understand, easy to export data set that fits my needs perfectly. Thanks! –  Elbelcho May 10 '11 at 13:36
    
Excellent, great stuff! –  Hairy May 11 '11 at 7:08
add comment

Fusion Table basic example

enter image description here

Spatial Query set in the code:

layer.setQuery("SELECT Country FROM 188044 WHERE ST_INTERSECTS(Country, RECTANGLE(LATLNG(35.77, -12.57), LATLNG(66.6, 37.3)))");

Source: http://homepage.ntlworld.com/keir.clarke/web/fusion2.htm

from: http://googlemapsmania.blogspot.com/2010/11/spatial-queries-added-to-fusion-tables.html

share|improve this answer
add comment

In your crime incident table you are going to need some information that connects to your neighborhood. Your neighborhood polygon doesn't contain all the addresses within it so your best bet would be to either A) get some street, parcel or building data that contains addresses that match your list or B) open up your crime table and add a column for neighborhood. then select the address within your neighborhood and populate the name/ID of the neighborhood it matches (this means you have to add a column in your neighborhood polygon and add the same ID) Basically you need to have a way to let the spatial query know that these addresses belong to this neighborhood.
Since your table is not a point feature class (I assume) you will have to do a join based on the table. To do this you open ArcMap, click add features, browse to find your table and neighborhood, right click on your neighborhood, click join> and follow the prompts to join attributes from a table.

share|improve this answer
    
Well, that's the problem, the crime data is for the whole city, and I want to filter it down so that I can see which specific crime incidents happened in this neighborhood. –  Elbelcho May 6 '11 at 13:46
1  
Do you have any other GIS data? Do you have parcels or streets? –  Meg McG May 6 '11 at 14:56
add comment

You say that you have a spatial representation of the neigborhoods but the crime data is just addresses.

there is to ways to connect the crimes to the neighborhoods.

get a list of all addresses in the neighborhoods and join against that list. that is a non spatial solution.

or you need to get some spatial representation of the crimeinformation.

if you have coordinates for the crimes you join the neighborhood polygon with the crimepoints with an intersects statement. then it is a spatial solution.

/Nicklas

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.