NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum

Hi All,

My idea is to calculate the max speed by using the open street apis giving latitude and longitude as inputs I am able to do it when the osm type is "way" . But for some of the latitude and longitude the osm type returned is "node" instead of "way" (It may be relation also) for which i am not able to calculate the max speed . Is there a possibility that a particular node can have a max speed associated ?

Any thoughts ?

asked 10 Jul '15, 08:19

Gauravk's gravatar image

Gauravk
16557
accept rate: 0%


Which API are you using exactly? You shouldn't use the main API for such queries, instead use Overpass API which is both faster and more flexible.

With Overpass API you can specify the types of elements to query for. This means you can query just for ways if you like, see an example on overpass turbo.

For answering your original question: A maxspeed tag on a node doesn't really make sense because it lacks one important information: where does it start and where does it end? So this is no typical tagging scheme and can be completely ignored. The only useful meaning is combining it with a traffic_sign tag. But in this case it mainly refers to a traffic sign which is mostly useful for other mappers and less useful for routers.

permanent link

answered 10 Jul '15, 11:09

scai's gravatar image

scai ♦
33.3k21309459
accept rate: 23%

Thanks for your response.

I use http://nominatim.openstreetmap.org/reverse to get the osm_id by giving the latitude and longitude

Then using http://overpass-api.de/api/interpreter?data=way(osm_id);out; i get the maxspeed or highway type only if the first url gives a "way" type .

(10 Jul '15, 14:43) Gauravk
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×92
×46
×12
×10

question asked: 10 Jul '15, 08:19

question was seen: 3,781 times

last updated: 10 Jul '15, 14:43

NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum