read.rain: Retrieve rain data from City of Portland Hydra network.

View source: R/read.rain.r

read.rainR Documentation

Retrieve rain data from City of Portland Hydra network.

Description

The City of Portland operates a rain gauge network. This function retrieves rain data from the SQL server database using the USP_MODEL_RAIN stored procedure. The stored procedure summarizes the data within a prespecified period of time (e.g., hourly) and returns the summarized data rather than raw tips.

Usage

read.rain(
  station = 160,
  start = end - 7,
  end = Sys.Date(),
  daypart = c("day", "hour", "minute", "month", "year"),
  interval = 1,
  server = NULL,
  format = T
)

read.rain.locations(server = NULL)

Arguments

station

a vector of hydra station codes; the default is the WPCL gauge

start

the start date as a Date object

end

the end date as a Date object

daypart

the unit in which the interval is specified

interval

the interval over which the data should be summarized

format

logical, TRUE will perform some data formatting, FALSE will return the data.frame exactly as it was returned by the database

dsn

Alternate dsn for the NEPTUNE database - for access to production or test instances.

Value

a data.frame of rain data


jasonelaw/BESdata documentation built on Nov. 3, 2023, 9:32 a.m.