Question

How to count per segment

  • 14 November 2016
  • 3 replies
  • 1 view

Hi,

Simple question, there is Line feature that are multiple segments with direction (Blue and orange lines), each having individual Id. I would like to count the no. of black line touching per segment.

Let me know if any further info is needed.

Must be simple but, I'm stuck.

Thanks in Advance,

Sani.


3 replies

Userlevel 4

Considering the blue line, how do you distinguish the two black lines from the orange continuation?

For a somewhat manual approach, the TopologyBuilder could be a start.

Badge +16

Another approach might be the LineOnLineOverlayer + Aggregator for the counting, see attached workspace

how-to-count-per-segment.fmw

Badge +22

Assuming the black lines are in a different dataset or have some other way of distinguishing them from the coloured lines.

 

 

I would use a SpatialRelator with the Requestor being the segments, and the Supplier the black lines, Test to Perform would be either Touches or Intersects, and the _related_candidates are the number of black lines that touch the segment.

Depending on your input geometry you may need to use a Path Splitter on you coloured lines to break them into individual features prior to the Spatial Relator.

Reply