5

Further to my previous question I was wondering if it is possible to add dummy node data without to do routing analysis.

ISSUE

  • I have a polygon layer that represents zonal attributes
  • I created a centroid (point layer) for each polygon
  • I would like to add the new points to the database with "dummy" links to the nearest highway or nearest road of a certain classification
  • Route from between all the nodes to develop a trip matrix

Is this possible with OSM and pgRouting?

NOTE I will add more details to this question tomorrow

dassouki
  • 8,563
  • 12
  • 64
  • 115
  • The bounty is still in 'a grace period' (it still can be given 24hrs after the expiry time) - http://meta.stackexchange.com/questions/16065/how-does-the-bounty-system-work – Mapperz Apr 12 '13 at 20:09

1 Answers1

3

You'll have to create an INSERT statement that constructs a line from your centroid to your road segment.

Some useful postgis functions would be:

  • st_make_line
  • line_locate_point(ST_GeometryN(road.geom, 1), centroid.geom)
  • st_distance(road.geom, centroid.geom)
Samuel
  • 606
  • 3
  • 5