Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get electric car charging point data from OSM #73

Open
Robinlovelace opened this issue Mar 24, 2021 · 0 comments
Open

Get electric car charging point data from OSM #73

Robinlovelace opened this issue Mar 24, 2021 · 0 comments

Comments

@Robinlovelace
Copy link
Member

See below:

library(osmextract)
#> Data (c) OpenStreetMap contributors, ODbL 1.0. https://www.openstreetmap.org/copyright.
#> Check the package website, https://docs.ropensci.org/osmextract/, for more details.

# get help on getting data
?oe_get

q = "SELECT * FROM 'points' WHERE amenity IN ('charging_station')"
extra_tags = "amenity"
region_name = "Isle of Wight"
electric_charging_points = oe_get(place = region_name, query = q, extra_tags = extra_tags)
#> The input place was matched with: Isle of Wight
#> Warning: The query selected a layer which is different from layer argument. We
#> will ignore the layer argument.
#> The chosen file was already detected in the download directory. Skip downloading.
#> The corresponding gpkg file was already detected. Skip vectortranslate operations.
#> Reading layer `points' from data source `/mnt/57982e2a-2874-4246-a6fe-115c199bc6bd/data/osm/geofabrik_isle-of-wight-latest.gpkg' using driver `GPKG'
#> Simple feature collection with 11 features and 11 fields
#> Geometry type: POINT
#> Dimension:     XY
#> Bounding box:  xmin: -1.296974 ymin: 50.65497 xmax: -1.072088 ymax: 50.73917
#> Geodetic CRS:  WGS 84
mapview::mapview(electric_charging_points)

Created on 2021-03-24 by the reprex package (v1.0.0)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant