using the new data management platform DBHydro Insights, this function using the Districts API access to retrieve data from the database

insight_fetch_daily(
  startDate,
  endDate,
  dbkey,
  datum = NULL,
  period = NULL,
  reportType = "timeseries",
  format = "json",
  ...
)

Arguments

startDate

Required as a Date as.Date or other format (i.e. as.POSIXct)

endDate

Required as a Date as.Date or other format (i.e. as.POSIXct)

dbkey

Required as a character, defines which data is to be accessed. Also called Timeseries ID

datum

vertical datum of presented data (NGVD29 or NAVD88)

period

Timespan of data requested (1day, 3days, 1week, 2 weeks, 30days, 365days, por)

reportType

default is timeseries, Defines the structure of the data presentation see user manual for more

format

set to json for ease of data retrieval

...

not used, to pass argument along to other functions, in the future.

Examples

if (FALSE) {
# Daily Discharge Data
sdate <- as.Date("2001-05-01");
edate <- as.Date("2002-05-01");
dat <- insight_fetch_daily(sdate,edate,"FE771")

# retrieve metadata
attr(dat,"metadata")
}