0

I have points that fall in the middle of city streets (so not at an intersection). I would like to automate (ideally, with python) a way to identify the cross streets that these points are between. For example, in the screenshot, the point falls on West 231 Street. I would like to find a way to automate a result that returns Palisade Avenue and Independence Avenue. My points file has columns for these cross streets, with the ultimate goal of placing those selected values there.

enter image description here

closed as too broad by PolyGeo Feb 8 '18 at 22:45

Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • Welcome to GIS SE! As a new user be sure to take the Tour to learn about our focussed Q&A format. I recommend not thinking about GIS SE as being some sort of online GIS tutor. For your questions to be answered here they should as much as possible describe not just what you want to do, but precisely what you have tried and where you are stuck trying that. – PolyGeo Feb 8 '18 at 22:44
  • For questions that involve code we ask that you show us where you are stuck with your own code by including a code snippet in your question. There is an edit button beneath your question which will enable you to do that and a {} button that enables you to format any highlighted code nicely. – PolyGeo Feb 8 '18 at 22:44
1

This ESRI blog post and a subsequent response provide a good start to this.

They recommend unsplitting the lines (to account for attribute changes in the lines which aren't representative of actual intersections), then use the resulting layer in the Intersect tool to output individual points (the intersections). These points are then spatially joined to the intersecting streets.

A second spatial join (see the response, linked above) adds the intersection field to the roads layer.

If you need the intersection points themselves, you can use cursor to iterate through the individual points and select by attributes which contain the streetname. Depending on the extent of your data, you may wish to combine this with a select by location first to limit intersections with similar names.

Otherwise if you just need the intersection streetnames, try splitting the blog's proposed "IntersectionList" field on the "&" and writing the results to your columns. Be sure to account for situations where more than two streets intersect (e.g. 3 road intersection) -- you may need to adjust the number of columns you are using to store this in the attribute table (check the Join_Count field the post states is created automatically during the spatial join).

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