Solved

Make flow map with points


Badge

Dear FME community.

I would like to make a flow map like in french "carte en oursin"

For do that, I've multiple group of points like this structure : One center with multiple destination for each group of points.

I tried to do that with this workbench :

Can you help me ?

Thank you.

icon

Best answer by takashi 16 May 2018, 12:25

View original

5 replies

Badge +10

Hi @lalandexavier,

I would use a NeighborFinder transformer and feed the destinations in the Base port and the Centre in the Candidate port. You can set the Id as GroupBy. Next you can add a VertexCreator with 'Insert Point At Index' using the _closest_candidate_x and _closest_candidate_y on index 0.

UPDATE: Using 'Insert Point At Index' and index 0 will cause an error. You can use 'Add Vertex' and if you would like to have the line running from the centre to the destination you could add an Orientor

Userlevel 2
Badge +17

Hi @lalandexavier, I would use a CoordinateExtractor, a FeatureMerger and a VertexCreator. In addition, you can reverse the orientation of resulting lines with the Orientor if necessary.

Badge

Hi @lalandexavier,

I would use a NeighborFinder transformer and feed the destinations in the Base port and the Centre in the Candidate port. You can set the Id as GroupBy. Next you can add a VertexCreator with 'Insert Point At Index' using the _closest_candidate_x and _closest_candidate_y on index 0.

UPDATE: Using 'Insert Point At Index' and index 0 will cause an error. You can use 'Add Vertex' and if you would like to have the line running from the centre to the destination you could add an Orientor

Thank you very much lars_de_vries both ideas with takashi are good !

 

Badge

Hi @lalandexavier, I would use a CoordinateExtractor, a FeatureMerger and a VertexCreator. In addition, you can reverse the orientation of resulting lines with the Orientor if necessary.

Thank you very much takashi that's work ! It's perfect

 

 

Userlevel 4
Upvoted for brilliant illustration of the problem :-)

Reply