Learn R Programming

countyfloods (version 0.0.2)

gage_extract: Get gage meta-data for a county

Description

This function uses the whatNWISsites function from the dataRetrieval package to pull information on all stream gages within a county and then adds the county FIPS code as an additional column to the dataframe.

Usage

gage_extract(county_cd, start_date, end_date)

Arguments

county_cd

Character vector with the county FIPS code

start_date

Character string with the starting date, using "YYYY-MM-DD" notation.

end_date

Character string with the end date, using "YYYY-MM-DD" notation.

Value

A dataframe with information about stream gages within a county for a specified time frame. This information typically includes each gage's site number, station name, agency code, site type code, latitude, longitude, and county code. See the whatNWISsites function from the dataRetrieval package for details.

See Also

whatNWISsites

Examples

Run this code
# NOT RUN {
gage_extract("12086", start_date = "2000-01-01", end_date = "2009-12-31")

# }

Run the code above in your browser using DataLab