Skip to main content

Can anyone help with the easiest way to do this within FME? I have a 2 point shapefiles (A and 😎 and 1 line shapefile (C). Within shapefile A, each point is associated with one point in shapefile B (ex: points oid 1,5,6,8 belong to point oid 2 in shapefile B. I am wanting each independent distance from point 2 to each associated point (points 1,5,6,8). These points all fall on the same line. I've looked at using pointonlineoverlayer and measure generator, but I am missing something in the process and not getting the results I need.

Thanks!

So I'm looking for distance from HOU_CLUSTER 1 point to each selected point.


Have you looked at the ShortestPathFinder?


As @jdh mentioned the ShortestPathFinder is the transformer that should be able to do this, if your lines network is closed.

If that is not the case the Snapper can help closing the network.

If you look for the distance from each point to the CLUSTER, not over a connected network, the NeighborFinder should be used (I notice in the image not all points are connected by a network to the cluster).


Hi,

Have you tried Lenghtcallculator ?


Hi @laceymorris, assuming that the lines belong to a connected network, you can set measures which indicate the distances from the common starting node (say "source") with the NetworkCostCalculator (Output Optimal Cost As: Measures), and then transfer the measure value to a point feature which is on a network node or line with the PointOnLineOverlayer. The measure value of a point can be extracted as a feature attribute with the MeasuerExtractor (Type: Point).

If the lines don't form a network, consider using the TopologyBuilder to construct a network beforehand.


Reply