Download 'TWDB' Coastal Measurement Data
Source:R/download_coastal_site_data.R
download_coastal_site_data.Rd
Download 'TWDB' Coastal Measurement Data
Usage
download_coastal_site_data(
station,
parameter,
start_date,
end_date,
binning = "day",
opts = list()
)
Arguments
- station
character, required.
- parameter
character, required.
- start_date
character, required. Format must be
yyyy-mm-dd
.- end_date
character, required. Format must be
yyyy-mm-dd
.- binning
character. One of
"mon", "day", "hour"
. Default is"day"
- opts
list of curl options passed to crul::HttpClient()
Examples
download_coastal_site_data(station = "MIDG", parameter =
"seawater_salinity", start_date = "2010-01-01", end_date = "2010-12-31",
bin = "hour")
#> # A tibble: 8,559 × 2
#> value datetime_utc
#> <dbl> <chr>
#> 1 17.9 2010-01-01T06:00:00.000Z
#> 2 17.6 2010-01-01T07:00:00.000Z
#> 3 17.2 2010-01-01T08:00:00.000Z
#> 4 17.0 2010-01-01T09:00:00.000Z
#> 5 15.2 2010-01-01T10:00:00.000Z
#> 6 14.6 2010-01-01T11:00:00.000Z
#> 7 14.7 2010-01-01T12:00:00.000Z
#> 8 14.7 2010-01-01T13:00:00.000Z
#> 9 14.5 2010-01-01T14:00:00.000Z
#> 10 14.0 2010-01-01T15:00:00.000Z
#> # … with 8,549 more rows