ArcGIS Online hosted feature service in lezen in R
This example demonstrates how to read and visualize the Dutch national heritage register (Rijksmonumenten) from an ArcGIS Online hosted feature service. It shows the full workflow of querying the service's metadata, counting features, and paginating through all 64,020 records, then maps them with `tmap` and `sf`. The code uses the `httr` and `jsonlite` packages to construct URL requests and parse JSON, while `sf::st_read()` reads the GeoJSON response. It explicitly checks pagination support via the service’s `advancedQueryCapabilities` and explains an anomaly where the initial page returns more records than `maxRecordCount` suggests. The final map is rendered with `qtm()`, and summary statistics (min/max OBJECTID) are computed via the service’s `outStatistics` parameter.
AI-generated description