Skip to contents

Function to get all NNI data available for a given year.

Usage

sc_get_nni(
  year,
  aoi = NULL,
  comid = NULL,
  showAreaSqKm = TRUE,
  state = NULL,
  county = NULL,
  region = NULL,
  conus = NULL,
  showPctFull = NULL,
  countOnly = NULL
)

Arguments

year

Years(s) of NNI metrics to query. Only valid NNI years are accepted (1987:2017) Syntax: year=<year1>,<year2>

aoi

Specify the area of interest described by a metric. By default, all available areas of interest for a given metric are returned. Syntax: areaOfInterest=<value1>,<value2> Values: catchment|watershed

comid

Return metric information for specific COMIDs Syntax: comid=<comid1>,<comid2>

showAreaSqKm

Return the area in square kilometers of a given area of interest. The default value is true. Values: true|false

state

Return metric information for COMIDs within a specific state. Use a state's abbreviation to query for a given state. Syntax: state=<state1>,<state2>

county

Return metric information for COMIDs within a specific county. Users must use the FIPS code, not county name, as a way to disambiguate counties. Syntax: county=<county1>,<county1>

region

Return metric information for COMIDs within a specified hydroregion. Syntax: region=<regionid1>,<regionid2>

conus

Return all COMIDs in the conterminous United States. The default value is false. Values: true|false

showPctFull

Return the pctfull for each dataset. The default value is false. Values: true|false

countOnly

Return a CSV containing only the row count (ROWCOUNT) and the column count (COLUMNCOUNT) that the server expects to return in a request. The default value is false. Values: true|false

Value

A tibble of desired StreamCat metrics

Author

Selia Markley

Examples

if (FALSE) { # \dontrun{

df <- sc_get_nni(year='1987, 1990, 2005, 2017', aoi='cat,ws',
comid='179,1337,1337420')

df <- sc_get_nni(year='2015', aoi='cat',
comid='179', countOnly=TRUE)

df <- sc_get_nni(comid='179', year='2011, 2012', aoi='ws')

df <- sc_get_nni(year='2015, 2016, 2017', county='41003', aoi='ws')
} # }