Is it possible to download establishment's data in a given location? I do not need it mapped out. For example, I want all the New York restaurants and their information in an excel file.

BTW, I have almost zero working knowledge in IT.

asked 12 Jan '15, 09:56

joshant's gravatar image

joshant
41114
accept rate: 0%

edited 12 Jan '15, 20:04

aseerel4c26's gravatar image

aseerel4c26 ♦
32.1k16239551


Overpass API, an API, can give you data in CSV format, which should be loadable into Excel.

Here's a sample Overpass query that gives a CSV file of restaurants, plus some data about them, just move the map to NY, and press Run again.

permanent link

answered 12 Jan '15, 13:22

rorym's gravatar image

rorym
5.3k144898
accept rate: 11%

edited 12 Jan '15, 14:08

2

@joshant: and in case you do not yet know how specific types of "establishments" are described in the OpenStreetMap data, have a look at Map Features (takes a while to load) or which-tags-do-i-use. In your restaurant case the usual tag is amenity=restaurant which you will recognize in in rorym's sample query code ("amenity"="restaurant").

(12 Jan '15, 14:20) aseerel4c26 ♦
2

The print section generated by overpass turbo is not ideal for CSV output mode, as you get a lot of almost empty lines starting at about row 215.

Those are all the nodes belonging to some restaurant way; they're primarily needed, if you want to draw some buildings on a map and need all coordinates.

My recommendation here is to just replace that section by out center;

This is how the query would then look like: http://overpass-turbo.eu/s/6ZA

(12 Jan '15, 17:55) mmd
1

Another variant on the query, missing @mmd's suggestion with uses the around operator to point at NYC directly http://overpass-turbo.eu/s/6ZD

(12 Jan '15, 18:58) SK53 ♦

@SK53: while you are at "variants … is there a way to use the boundary relation of New York – in case one strictly wants to only get restaurants from New York (like in the example above)? – Okay, apparently not (at least not for all object types).

(12 Jan '15, 19:11) aseerel4c26 ♦
2

@aseerel4c26: yes, you could refer to that boundary relation as well: http://overpass-turbo.eu/s/6ZI

(12 Jan '15, 19:35) mmd
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:

×240
×27
×7
×6

question asked: 12 Jan '15, 09:56

question was seen: 2,735 times

last updated: 12 Jan '15, 20:04

powered by OSQA