Skip to main content

I have 1 Road(Line) layer with so many attributes e.g. Name, Speed, Direction etc. I want to find if any segment of 1 continuous road(line) has different names.

Ex. ABC Road is of 5 KMs but in database there are few small segments which has name as XYZ Road, abcd Street etc. How to detect these segments.

@takashi @david_r

 

Thanks

 

I want to detect this type of issue


This will find a segment of road that matches the situation you describe above:

none2none.fmw

The key here is to use a SpatialRelator to build a list of segments that touch, then followed by a ListHistogrammer to see how many unique names are in that list. My assumption is that if a line has 2 touching segments but those 2 segments have the same name it is probably the kind of thing you're looking for.

A situation where ABC Street turns into DEF Street and then into GHI Street before going back to ABC Street will not be picked up by this, nor does it account for spelling mistakes.


This will find a segment of road that matches the situation you describe above:

none2none.fmw

The key here is to use a SpatialRelator to build a list of segments that touch, then followed by a ListHistogrammer to see how many unique names are in that list. My assumption is that if a line has 2 touching segments but those 2 segments have the same name it is probably the kind of thing you're looking for.

A situation where ABC Street turns into DEF Street and then into GHI Street before going back to ABC Street will not be picked up by this, nor does it account for spelling mistakes.

HI @redgeographics Thanks for your effor and support 🙂. It's working good but still there are cases which not detecting by this provided WB. Pls see the image. In the below segment Name changes from Sardar Vallabhai Patel marg to NH6 at a node( no other road segement there) & than NH6 continues , I need both segment where name changes


HI @redgeographics Thanks for your effor and support 🙂. It's working good but still there are cases which not detecting by this provided WB. Pls see the image. In the below segment Name changes from Sardar Vallabhai Patel marg to NH6 at a node( no other road segement there) & than NH6 continues , I need both segment where name changes

Are you referring to the 1st or 2nd line from the left?


Are you referring to the 1st or 2nd line from the left?

The 2nd one


The 2nd one

Ok, and if I understand you correctly you want to see the locations where the name changes, right? In that case, if you use a LineCombiner to join together all line segments with the same name and a pair of CoordinateExtractors followed by a VertexCreator to create points of the first and last node of every line, then remove duplicates you should have them.


Ok, and if I understand you correctly you want to see the locations where the name changes, right? In that case, if you use a LineCombiner to join together all line segments with the same name and a pair of CoordinateExtractors followed by a VertexCreator to create points of the first and last node of every line, then remove duplicates you should have them.

Ok, thanks for your help. I'll try & let you know the result.

Thanks again


Reply