Learn R Programming

aurin (version 0.6.0)

aur_get: Fetch AURIN dataset.

Description

Query data using WFS getFeature.

Usage

aur_get(open_api_id, crs = "EPSG:4326", params = NULL)

aur_build_request( open_api_id, crs = "EPSG:4326", params = NULL, outputFormat = "application/json" )

Arguments

open_api_id

Character. You can find the layer names for AURIN<U+2019>s datasets by browsing the Data Catalogue. The layer name is found in the <U+2018>AURIN Open API ID<U+2019> field in a dataset<U+2019>s metadata.

crs

default as "EPSG:4326". The Coordinate Reference System you wish to use

params

a named list that contains additional parameters to be used when constructing a WFS GetFeature request. This is useful when you know the ID of a specific feature or the maximum number of features you want to query. See examples here.

outputFormat

default as "application/json", see https://docs.geoserver.org/latest/en/user/services/wfs/outputformats.html for other available options.

Value

an sf::sf object.

Examples

Run this code
# NOT RUN {
# follow the example in <https://aurin.org.au/resources/aurin-apis/aurin-open-api-and-r/>
# }
# NOT RUN {
aur_get("aurin:datasource-UQ_ERG-UoM_AURIN_DB_public_toilets")

# Get the first 10 features.
aur_get(
   open_api_id,
   params = list(maxFeatures = 10)
 )
# }

Run the code above in your browser using DataLab