Question

Locate points that are snapped to an edge of a line but not a vertex or end point

  • 22 July 2016
  • 7 replies
  • 19 views

Badge

I am trying to find a way of identifying points that fall on a line, but not at a vertex or an end point. I can use SpatialRelator (contains/touches) to locate points that match vertices or end points of a line, but currently don't have a method for selecting those that fall purely on the 'edge'. I am basically trying to recreate the 'select by location - within/completely within' functionality in ArcMap. It would be good if I could do this without having to use Python to call Esri functionality.


7 replies

Userlevel 1
Badge +21

Can you turn all your lines into points with the chopper with maximum vertices set to 1 and then use the PointOnPointOverlayer to identify any points that don't overlap?

Userlevel 4

Several options with slightly different outcomes / specialties:

  • PointOnLineOverlayer
  • Intersector
  • TopologyBuilder

If you need some notion of tolerance, consider the NeighborFinder.

Badge

Can you turn all your lines into points with the chopper with maximum vertices set to 1 and then use the PointOnPointOverlayer to identify any points that don't overlap?

Thnaks for your answer, but I don't think this method will identify those point that actually fall on the line though, just points that don't fall on a vertex or end point. There will be points in the data that aren't on the line at all and I'm not interested in those.

Userlevel 1
Badge +21

Thnaks for your answer, but I don't think this method will identify those point that actually fall on the line though, just points that don't fall on a vertex or end point. There will be points in the data that aren't on the line at all and I'm not interested in those.

Posted before finishing, once you have identified points that don't overlap with end points or vertexs you can then use the point on line overlayer to identy which fall on the line.

Badge

Can you turn all your lines into points with the chopper with maximum vertices set to 1 and then use the PointOnPointOverlayer to identify any points that don't overlap?

I had tried PointOnLineOverlayer earlier, but with a point tolerance of 0, so again this only seemed to work where points matched existing vertices of the lines. If I slightly increase this tolerance it seems to use the additional points

Badge

Several options with slightly different outcomes / specialties:

  • PointOnLineOverlayer
  • Intersector
  • TopologyBuilder

If you need some notion of tolerance, consider the NeighborFinder.

I think I am going to take another look at the PointOnLineOverlayer. I had originally used it but with a point tolerance of 0 so it was only breaking the lines where points matched existing vertices on the line. Tweaking this setting seems to generate results more along the lines of what I am hoping for.

Userlevel 2
Badge +17

I think I am going to take another look at the PointOnLineOverlayer. I had originally used it but with a point tolerance of 0 so it was only breaking the lines where points matched existing vertices on the line. Tweaking this setting seems to generate results more along the lines of what I am hoping for.

Hi @iew, generally FME computes spatial relationships with full precision of the floating point number. It's different from other softwares such as ArcGIS, which are lenient to a slight computational error. Since there is an unavoidable computational error always in any calculation, the PointOnLineOverlayer with tolerance of 0 cannot determine whether a point is located on a line except some special cases (e.g. the case where the point exactly matches a vertex of the line, or the line is exactly parallel to the X or Y axis). Try setting a slight tolerance, e.g. 1e-8 or so, to the tolerance parameter.

Reply