get_envirologger_data: Function to get observational data from Envirologger API.

Description Usage Arguments Value Author(s) See Also Examples

View source: R/get_envirologger_data.R

Description

Function to get observational data from Envirologger API.

Usage

1
2
3
get_envirologger_data(user, key, station, start = NA, end = NA,
  tz = "UTC", remove_duplicates = TRUE, interval = "24 hour",
  verbose = FALSE)

Arguments

user

An Envirologger API user-name.

key

An Envirologger API key for user.

station

A vector of station codes to download. Station codes are integers and get_envirologger_stations can be used to find these codes.

start

What is the start date of data to be returned? Ideally, the date format should be yyyy-mm-dd, but the UK locale convention of dd/mm/yyyy will also work. Years as strings or integers work too and will floor-rounded.

end

What is the end date of data to be returned? Ideally, the date format should be yyyy-mm-dd, but the UK locale convention of dd/mm/yyyy will also work. Years as strings or integers work too and will be ceiling-rounded.

tz

Time zone for the observations' dates. The default is "UTC".

remove_duplicates

Should "true" date-station-variable-value duplicates be removed? Default is TRUE as this is common.

interval

How much data should the function request from the API for each iteration?

verbose

Should the functions give messages?

Value

Tibble.

Author(s)

Stuart K. Grange

See Also

API Documentation, get_envirologger_stations

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
## Not run: 

# Get some data for a made up station
data_air <- get_envirologger_data(
  user = user, 
  key = key, 
  station = 1001, 
  start = "2016-06-20", 
  end = "2016-06-21"
)


## End(Not run)

skgrange/envirologgerr documentation built on July 23, 2019, 6:04 p.m.