Returns a list of sites from the NWIS web service. This function gets the data from: https://waterservices.usgs.gov/docs/site-service/. Mapper format is used
Arguments
- ...
see https://waterservices.usgs.gov/docs/site-service/ for a complete list of options. A list (or lists) can also be supplied.
Value
A data frame with at least the following columns:
Name | Type | Description |
agency_cd | character | The NWIS code for the agency reporting the data |
site_no | character | The USGS site number |
station_nm | character | Station name |
site_tp_cd | character | Site type code |
dec_lat_va | numeric | Decimal latitude |
dec_long_va | numeric | Decimal longitude |
queryTime | POSIXct | Query time |
There are also several useful attributes attached to the data frame:
Name | Type | Description |
url | character | The url used to generate the data |
queryTime | POSIXct | The time the data was returned |
Examples
# \donttest{
siteListPhos <- whatNWISsites(stateCd = "OH", parameterCd = "00665")
#> GET:https://waterservices.usgs.gov/nwis/site/?stateCd=OH¶meterCd=00665&format=mapper
oneSite <- whatNWISsites(sites = "05114000")
#> GET:https://waterservices.usgs.gov/nwis/site/?sites=05114000&format=mapper
# }