Select to view content in your preferred language

Analysis of Polylines on both sides of separate polyline featureclass

3409
5
Jump to solution
08-20-2014 11:00 AM
JamesBooth1
Deactivated User

I have two separate polyline feature classes. One of them contains roads. The other feature class represents sidewalks. I would like to determine the % of roads with sidewalks on both sides of the road. I'm curious to know if anyone has come up with a solution to this sort of question. Appreciate any advice or help!

0 Kudos
1 Solution

Accepted Solutions
OwenEarley
Frequent Contributor

Hi James,

Check out the attached toolbox and python script. Please note this has had very limited testing so you should run this using a copy of your data in a file geodatabase and verify that the results are valid.

The tool uses road and footpath layers and a search distance as inputs. Also there is the option to specify a workspace if you want to keen the analysis layers used in the calculations.

footpaths.png

Basically the script creates perpendicular lines from the mid-point of each road feature, these lines will extend out to your search distance value. The script then tests if the line intersects a footpath to the right or left of the road line and creates summary statistics that are added to the road layer. These are two new fields:

  • PathCount - this should be either 1 or 2 (unless your search distances are too large)
  • PathSide - Right, Left or Both

You can then calculate your percentage based on the number of PathSide = 'Both' records compared to your total road count.

Hope this helps.

Owen

Spatial XP

View solution in original post

0 Kudos
5 Replies
XanderBakker
Esri Esteemed Contributor

Could you post a small part of both featureclasses? That will make it easier to see what implications there might be. This will probably require some programming in python or maybe in ArcObjects.

0 Kudos
JamesBooth1
Deactivated User

Sorry, I'm not allowed to post our data online. Thank you for reaching out however.

0 Kudos
OwenEarley
Frequent Contributor

Hi James,

Check out the attached toolbox and python script. Please note this has had very limited testing so you should run this using a copy of your data in a file geodatabase and verify that the results are valid.

The tool uses road and footpath layers and a search distance as inputs. Also there is the option to specify a workspace if you want to keen the analysis layers used in the calculations.

footpaths.png

Basically the script creates perpendicular lines from the mid-point of each road feature, these lines will extend out to your search distance value. The script then tests if the line intersects a footpath to the right or left of the road line and creates summary statistics that are added to the road layer. These are two new fields:

  • PathCount - this should be either 1 or 2 (unless your search distances are too large)
  • PathSide - Right, Left or Both

You can then calculate your percentage based on the number of PathSide = 'Both' records compared to your total road count.

Hope this helps.

Owen

Spatial XP

0 Kudos
JamesBooth1
Deactivated User

HI Owen, thank you so much for your help. I'd love to try this script. However, where do I find the attachment? I'll keep looking, but I'm not seeing it. Thanks!

0 Kudos
OwenEarley
Frequent Contributor

A the bottom of my post there should be an attachment with a file Footpaths.zip.

In case there is some issue and it is not visible the file is here:

https://community.esri.com/servlet/JiveServlet/download/398901-71059/Footpaths.zip

0 Kudos