[Qgis-user] QGIS to load spefific OpenStreetMap data
Stefan Keller
sfkeller at gmail.com
Wed May 15 12:25:42 PDT 2019
Dear all
Thanks so much for your feedback.
Am Mi., 15. Mai 2019 um 01:24 Uhr schrieb Jorge Gustavo Rocha
<jgr at geomaster.pt>:
> better than using the bounding box. Good point! We can drop the 'shop'
> key and simply write: 'bakery or supermarket in Zurich' in the Wizard.
I do have a final enhancement :-).
On Tue, May 14, 2019 at 3:43 PM Jorge Gustavo Rocha <jgr at geomaster.pt> wrote:
> 7) Add layer to QGIS (eventually points and polygons; calculate
> the centroids for the polygons in QGIS)
After writing e.g. "bakery or supermarket in Uster" into the
Overpass-Turbo wizard, one generates the query.
Then the query can be enhanced by replacing node/way/lines to "nwr"
and "out body; >; out skel qt;" from the output section at the end to
"out center;".
The first is an abbreviation and the second generates nodes from areas.
This is the result I'd like to propose:
[out:json][timeout:25];
{{geocodeArea:Uster}}->.searchArea;
(
nwr["shop"="bakery"](area.searchArea);
nwr["shop"="supermarket"](area.searchArea);
);
out center;
Yours, Stefan
Am Mi., 15. Mai 2019 um 01:24 Uhr schrieb Jorge Gustavo Rocha
<jgr at geomaster.pt>:
>
> Hi,
>
> Thank you for the feedback, Clifford. Adding the suffix 'in Zurich' is
> better than using the bounding box. Good point! We can drop the 'shop'
> key and simply write: 'bakery or supermarket in Zurich' in the Wizard.
> Much better!
>
> Regards,
>
> Jorge Gustavo
>
>
> Às 00:02 de 15/05/19, Clifford Snow escreveu:
> > Stefan,
> > Let me make one suggestion to Jorge's overpass query. By using the
> > Overpass-Turbo Wizard search for shop=bakery or shop=supermarket in
> > Zurich. By adding in Zurich, the query will leave out objects in
> > adjacent cities.
> >
> > From the overpass turbo webpage, export the data as a geojson to load
> > into QGIS. Should work like a charm.
> >
> > Best
> > Clifford
> >
> > On Tue, May 14, 2019 at 3:43 PM Jorge Gustavo Rocha <jgr at geomaster.pt
> > <mailto:jgr at geomaster.pt>> wrote:
> >
> > Hi Stefan,
> >
> > Às 22:28 de 14/05/19, Stefan Keller escreveu:
> > > Hi,
> > >
> > > I'm preparing a talk about QGIS and OpenStreetMap for the annual
> > > meeting of the local QGIS chapter.
> > >
> > > => Question: How do you (users) load specific OSM data into QGIS, like
> > > for example all bakeries of Zurich? (ways/polygons as centroids?)
> > >
> >
> > I prefer to go to the overpass end point, to show how easy is to extract
> > OpenStreetMap data. It is faster than installing a plugin.
> >
> > For a talk, use the overpass Wizard to build the query.
> >
> > 1) Go to http://overpass-turbo.eu/
> > 2) Search for Zurich
> > 3) Open the Wizard
> > 4) Just type: bakery
> > 5) Build and run query
> > 6) Export as GeoJson
> > 7) Add layer to QGIS (eventually points and polygons; calculate the
> > centroids for the polygons in QGIS)
> >
> > Good luck for your presentation.
> >
> > Regards,
> >
> > Jorge Gustavo
> >
> > > Background: QGIS 2 had a built in downloader which is gone in QGIS 3.
> > > This instruction is 4y old [1], and this wiki page seems to be
> > > outdated too [2].
> > >
> > > I know, that QGIS can read OpenStreetMap XML (.osm) and .PBF files as
> > > vector layer. And I know about these two plugins: OSMDownloader [3]
> > > and QuickOSM [4].
> > >
> > > * OSMDownloader requests a bbox from the user, then downloads the
> > > whole area through the OSM API using the OGR OSM driver.
> > > * QuickOSM generates queries in outdated Overpass XML, but accepts
> > > also the newer Overpass QL language, like for example the following:
> > >
> > > [out:xml];
> > > area[name="Uster"];
> > > (
> > > nwr[shop~"supermarket|bakery"](area);
> > > );
> > > out body;
> > >> ;
> > > out skel qt;
> > >
> > > :Stefan
> > >
> > > [1] https://learnosm.org/en/osm-data/osm-in-qgis/
> > > [2] https://wiki.openstreetmap.org/wiki/QGIS
> > > [3] https://plugins.qgis.org/plugins/OSMDownloader/
> > > [4] https://plugins.qgis.org/plugins/QuickOSM/
> > > _______________________________________________
> > > Qgis-user mailing list
> > > Qgis-user at lists.osgeo.org <mailto:Qgis-user at lists.osgeo.org>
> > > List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> > > Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> > >
> >
> > --
> > Logo* Geomaster, LDA*
> > *VENHA DESCOBRIR O CAMINHO DO OPEN SOURCE CONNOSC**O
> >
> > *
> >
> > Avenida Barros e Soares
> > N.º 423, 4715-214 Braga
> > VAT/NIF510 906 109
> > Phone +351 253 680 323
> > Site geomaster.pt <http://geomaster.pt> <http://geomaster.pt>
> > GPS 41.53322, -8.41929
> >
> > ------------------------------------------------------------------------
> >
> > Jorge Gustavo Rocha
> > CTO
> >
> > Mobile +351 910 333 888
> > Email jgr at geomaster.pt <mailto:jgr at geomaster.pt>
> >
> >
> > _______________________________________________
> > Qgis-user mailing list
> > Qgis-user at lists.osgeo.org <mailto:Qgis-user at lists.osgeo.org>
> > List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> > Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> >
> >
> >
> > --
> > @osm_washington
> > www.snowandsnow.us <https://www.snowandsnow.us>
> > OpenStreetMap: Maps with a human touch
>
> --
> Logo* Geomaster, LDA*
> *VENHA DESCOBRIR O CAMINHO DO OPEN SOURCE CONNOSC**O
>
> *
>
> Avenida Barros e Soares
> N.º 423, 4715-214 Braga
> VAT/NIF510 906 109
> Phone +351 253 680 323
> Site geomaster.pt <http://geomaster.pt>
> GPS 41.53322, -8.41929
>
> ------------------------------------------------------------------------
>
> Jorge Gustavo Rocha
> CTO
>
> Mobile +351 910 333 888
> Email jgr at geomaster.pt
>
>
> _______________________________________________
> Qgis-user mailing list
> Qgis-user at lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
More information about the Qgis-user
mailing list