-
Notifications
You must be signed in to change notification settings - Fork 45
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
Why separating sf objects in osmdata object? #91
Comments
Thanks @niklaas for your interest in the package! I'd be interested to know what kind of queries you build that might lie beyond the As for the separation of objects - that is an attempt to interpret the OSM data format in OGC Simple Features (SF) terms. That's impossible to do strictly (there used to be a helpful discussion about this on the osm wiki, but that's been removed), but Simply packing all as a single type would require it to be a Now, regarding the helper functions: Yes, totally agree, and yes, please submit them to osmdata! That would be great. |
Thanks a lot for your sophisticated reply. I hope I will find more time to provide some code examples explaining my thoughts next weekend; for the moment, the following shall suffice: I prefer providing my own queries because this way I can already filter on the server side. Reducing the amount of response data greatly shortens converting it to Regarding the separation of objects: This came to my mind when I started implementing a function that queries for bus stations. In OSM some of them are points, others are areas (ways). And bringing Thank you for mentioning I hope I can provide better examples soon -- and eventually help to extend |
@niklaas That's a very convincing reason to write your queries directly! But note issue #74 - i just have to write a parser for the OSM In the meantime, I'll close this issue now, but hope for more input from you soon. In particular, if you could provide some examples of the difficulties you have in combining objects, we can see how we could adapt |
First and foremost, thanks a lot for providing this package. It makes working with OSM data quite handy. In my projects I mainly use
osmdata_sf
, building the Overpass query by myself. This is mainly because the requests are a bit more complex and I prefer filtering on the server side (if I can).I keep wondering why
osmdata_sf
separates sf objects in$osm_*
. Is this done on purpose i.e., a design principle, or due to technical limitations? I have been working on a function that combines the sf objects into a single one of type GEOMETRY, which is not that difficult to implement. I keep myself asking when I'll run into a dead end, probably starting to understand why you separate the objects in your package in the first place.Additionally, is there need for further helper functions that make accessing popular features (such as bus/metro/railway stations/routes, shops, etc.) easier? So any user unfamiliar with the Overpass API would gain access to the data -- at least to some extent. I thought about implementing these functions. I would either create my own R package for them (based on osmdata) or submit them to osmdata, if you think they would enhance the package.
The text was updated successfully, but these errors were encountered: