Skip to main content
Question

Snap points to measured lines, and assign measurement of the line

  • December 16, 2013
  • 6 replies
  • 110 views

I have tried a few different things but can't figure out how to get this to work. I would appreciate a little advice. I have a line file, with measures. I am trying to relate a point file to the lines, and assign a measure attribute to the points.

 

 

Right now I use the neighbourfinder tranformer to snap the points to the lines, grouping by a specific field. Then I go to ArcMap and use the 'Locate Features Along Routes' tool. The drawback is I can't group data when locating the features is ArcMap. If I have a point overlapping two routes I sometimes match to the wrong line. I'm dealing with over 1 million records so this is a lot to QC.

 

 

Is there any way to pull the measure from the line, and assign it to the points within FME?

 

 

Thanks,

 

Chris

6 replies

  • December 16, 2013
I am not completly sure about what you have to do (sorry for my awful english).

 

 

I understand from your explanation that what you are trying to do is to snap your points onto the lines specified by a "key field", and you want to add to these points a measured value held in one of the line's attributes.

 

 

First, if you have used a Snapper or Anchored Snapper transformer, did you group by your key field to avoid that the points could snap to the nearest line?

 

 

if don't, and the problem is only in the neighbourfinder, perhaps you could try using PointOnLineOverlayer, in which you can define too a tolerance for the distance in which it is going to look for the lines. here you can also group by your key field if it's neccesary. 

  • Author
  • December 17, 2013
Thanks for your reply. You have understood most of it. The trick is my lines are routes in a linear referencing system. The lines don't have an attribute in the table for the measures, they are attached to the geometry.

 

 

I know I can use the MeasureExtractor to get measures at each vertex. I have have a feeling you are on to something with the PointOnLineOverlayer. I may need to snip the lines at every point, and then extract the measure at of each segment.

 

 

I'll give that a try, but if you or anyone else has a more efficient was of doing this please let me know.

takashi
Contributor
Forum|alt.badge.img+19
  • Contributor
  • December 17, 2013
Hi Chris,

 

 

In my understanding, you are trying to set measurement value on the associated line to every point. If so, I think this procedure is one of possible ways: 1) PointOnLineOverlayer to split line at closer points. 2) Chopper to create every vertex point of split line. 3) MeasureExtractor (Geometry Type: Point) to extract measure value as attribute. 4) NeighborFinder to append the measure attribute to every original point.   original points --> BASE   chopped points --> CANDIDATE   MATCHED --> original points having measure value as attribute. 5) MeasureSetter (Type: Point) to set measure to every point.   Since the Chopper will create duplicated vertex points, the Snipper might be more efficient.

 

 

Takashi

  • Author
  • November 19, 2014
Hi Takashi,

 

 

I has almost been a year since you provided this response. I wanted to let you know I tried your solution and it worked exactly as expected. Thanks for your help.

 

 

Chris

kimo
Contributor
Forum|alt.badge.img+10
  • Contributor
  • October 7, 2018

There must be a better way to do this in 2018!

It looks like there is a new parameter on NeighborFinder that simply adds the measure from the line where it locates the nearest point on the line. "Take Measures/Z From Candidate" to get an xyzm point (or xym or xyz). But I get nothing.

The candidate line has measures in the inspector on the IFMELine x,y, <m> , but after the NeighborFinder it does not. I was expecting to use a MeasureExtractor to get the measure into an attribute, but all the points are rejected, presumably because it is not an x,y,m point.


kimo
Contributor
Forum|alt.badge.img+10
  • Contributor
  • October 10, 2018
kimo wrote:

There must be a better way to do this in 2018!

It looks like there is a new parameter on NeighborFinder that simply adds the measure from the line where it locates the nearest point on the line. "Take Measures/Z From Candidate" to get an xyzm point (or xym or xyz). But I get nothing.

The candidate line has measures in the inspector on the IFMELine x,y, <m> , but after the NeighborFinder it does not. I was expecting to use a MeasureExtractor to get the measure into an attribute, but all the points are rejected, presumably because it is not an x,y,m point.

For the record, the PointOnLineOverlayer does keep the m-value so I have used that. But it would still be useful if NeighborFinder also worked as documented.

 

 


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings