Skip to main content
Solved

NeighborFinder line

  • September 28, 2018
  • 5 replies
  • 221 views

Forum|alt.badge.img

Hi! I need to find a Neighbor Line to the line. I am interested in the average distance between these neighbors. Using NeighborFinder i have only the closest vertex of the line. I need tej farthest too.

Best answer by lau

You can split your line into vertex (LineDivider). Then for each vertex generated, find the closest line (NeighborFinder). You can calculate the average with a StatisticsCalculator

View original
Did this help you find an answer to your question?

5 replies

lau
Forum|alt.badge.img+3
  • Best Answer
  • September 28, 2018

You can split your line into vertex (LineDivider). Then for each vertex generated, find the closest line (NeighborFinder). You can calculate the average with a StatisticsCalculator


redgeographics
Celebrity
Forum|alt.badge.img+48

Here's a quick stab at it.

none2none.fmw

I break down the base and candidate lines into their indivudual points, then run the NeighborFinder without a max candidates or max distance parameter set. Then find the max distance per base point (by sorting the candidate list), aggregate them and the again sort the candidate list to get the max distance overall.


redgeographics
Celebrity
Forum|alt.badge.img+48
lau wrote:

You can split your line into vertex (LineDivider). Then for each vertex generated, find the closest line (NeighborFinder). You can calculate the average with a StatisticsCalculator

Ah jeez... I forgot about the StatisticsCalculator... Yeah, that would be a better solution than what I just built ;)

 

 


Forum|alt.badge.img
  • Author
  • September 28, 2018

Thanks a lof for your help @lau and @redgeographics

But i found a little problem. What if i have 2 lines candidates 1:on the left and 2: on the right side of the base-line? i would like to find a neighbor in each of candidates


lau
Forum|alt.badge.img+3
  • September 28, 2018
tramm wrote:

Thanks a lof for your help @lau and @redgeographics

But i found a little problem. What if i have 2 lines candidates 1:on the left and 2: on the right side of the base-line? i would like to find a neighbor in each of candidates

The NeighborPairFinder may help you. By setting a minimum separation angle of 180 (more or less) you may get what you need.

 

 


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