river_discharge: Retrieve river discharge data from the Open-Meteo API
Description
river_discharge() calls the Open-Meteo Global Flood API to obtain simulated
river discharge from the nearest river. Data obtained from the Global Flood
Awareness System (GloFAS). Forecasts and historical data is available.
river_discharge(location, start = NULL, end = NULL, daily = NULL, model = NULL)
Value
Requested river discharge data (m³/s) for the given location and time
period, as a tidy tibble.
Arguments
location
Required. The location for which data will be retrieved.
Supplied as either a c(latitude,longitude) WGS84 coordinate pair or a
place name string (with co-ordinates obtained via geocode()).
start, end
Start and end dates in ISO 8601 (e.g. "2020-12-31"). If no
dates are supplied, data for the next 3 months will be provided by default.
daily
Required. A weather variable accepted by the API, or list
thereof. See details below.
model
Supply to specify a model for forecasted values (defaults to
latest GloFAS model).
Details
You will need to specify at least one river discharge variable to retrieve
data for. These variables are sampled or aggregated at daily intervals, and
can be supplied as a list to request multiple variables over the same time
period.