Skip to main content
Question

Calculating journey times

  • November 5, 2014
  • 3 replies
  • 82 views

Hi

 

 

I have a set of origin points "origins" and a set of destination points "destinations" for which I would like to calculate the journey time between each of them (for every OD pair).

 

I also have network shapefile "network" that has the road centrelines which contains speed and distance attributes.

 

 

I think I need to use "shortest path finder" and weight it by the speed but is anyone able to help describe this in more detail/ suggest an alternative method to create a OD matrix with journey times and another with journey distances for each OD combination?

 

 

Thanks

 

 

3 replies

takashi
Contributor
Forum|alt.badge.img+19
  • Contributor
  • November 5, 2014
Hi,

 

 

I think the ShortestPathFinder is a good choice.

 

The transformer requires a "From-To" line (i.e. origin-destination) feature to compte a shortest path. So you will have to create every origin-destination line at first.

 

After reading the origin / destination points:

 

1) Add a CooridinateExtractor to extract x, y of each destination points.

 

2) Add a FeatureMerger, send the origin points to the Requestor port, the destination points to the Supplier port, and perform unconditional merging so that every destination x, y will be migrated to all the origin points.

 

Join On: 1 to 1 (constant)

 

Process Duplicate Suppliers: Yes

 

Duplicate Supplier List: _dest

 

3) Connect a ListExploder to the Merged port of the FeatureMerger, explode the features on the "_dest{}".

 

4) Add a VertexCreator to add destination coordinate to every origin point. i.e. transform the origin points into From-To (origin-destination) lines based on the destination x, y value.

 

 

You can then send the lines to the ShortestPathFinder to get shortest path for each origin-destination pair.

 

 

Takashi

gio
Contributor
Forum|alt.badge.img+15
  • Contributor
  • November 6, 2014
A unconditional merger is very usefull to have.

 

You can use the one in the fme-store.

 

Or build one yourself, wich is very easy.

 

 

I did, so i can merge more requestors simultaneously and to have tha ability to group during the merger.

 

 

Creting a network is also easy with fme by using topologybuilder(s) and NetworkFloworientors etc.

  • Author
  • November 6, 2014
thanks very much everyone! :)

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