Get Pegel-Online measurements
Usage
pegel_online_measurements(
station,
timeseries,
start = NULL,
end = NULL,
safe = TRUE,
refresh = FALSE
)Arguments
- station
Station UUID, name, or number.
- timeseries
Timeseries shortname.
- start
Start timestamp in ISO 8601.
- end
End timestamp in ISO 8601.
- safe
Logical; if
TRUE(default), apply rate-limiting and cache GET responses totools::R_user_dir("bunddev", "cache").- refresh
Logical; if
TRUE, ignore cached responses and re-fetch from the API (defaultFALSE).
Value
A tibble with one row per measurement:
- timestamp
Measurement timestamp string (character).
- value
Measured value (numeric).
- timestamp_time
Measurement timestamp as
POSIXctin Europe/Berlin.
Details
Returns measurement values for a station timeseries. Timestamps must be ISO 8601 strings. API documentation: https://pegel-online.api.bund.dev.
See also
pegel_online_timeseries() for metadata and
pegel_online_measurements_plot() for PNG plots.
Other Pegel Online:
pegel_online_measurements_plot(),
pegel_online_station(),
pegel_online_stations(),
pegel_online_timeseries(),
pegel_online_waters()
Examples
if (FALSE) { # \dontrun{
stations <- pegel_online_stations(params = list(limit = 1))
pegel_online_measurements(stations$uuid[[1]], "W",
start = "2024-01-01T00:00:00Z",
end = "2024-01-02T00:00:00Z"
)
} # }