Description Usage Arguments Value Examples
Function queries the CDEC site to obtain desired station data based on station, sensor number, duration code and start/end date. Use 'cdec_datasets()' to view an updated list of all available data at a station.
1 2 3 4 5 6 7 8 | cdec_query(
station,
sensor_num,
dur_code,
start_date = NULL,
end_date = NULL,
tzone = "America/Los_Angeles"
)
|
station |
three letter identification for CDEC location (example "KWK", "SAC", "CCR") |
sensor_num |
sensor number for the measure of interest. (example "20", "01", "25") |
dur_code |
duration code for measure interval, "E", "H", "D", which correspong to Event, Hourly and Daily. |
start_date |
date to start the query on. |
end_date |
an optional date to end query on, defaults to current date. |
tzone |
a time zone used. By default this is America/Los_Angeles, this accounts for daylight saving. |
data frame containing queried data from CDEC for a specific station, sensor, and date range
1 2 3 4 5 | ## Not run:
kwk_hourly_flows <- CDECRetrieve::cdec_query("KWK", "20", "H", "2017-01-01")
ccr_hourly_temps <- CDECRetrieve::cdec_query("CCR", "25", "H", Sys.Date())
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.