Description Usage Arguments Details Value Examples
Pulls data from NWIS internal servers using ODBC connection and returns a list containing dataframes.
1 2 3 |
DSN |
A character string containing the DSN for your local server |
env.db |
A character string containing the database number of environmental samples |
qa.db |
A character string containing the database number of QA samples |
STAIDS |
A character vector of stations IDs. Agency code defaults to "USGS" unless appended to the beginning of station ID with a dash, e.g. "USGS-123456". |
dl.parms |
A character vector of pcodes to pull data, e.g. c("00300","00915") or NWIS parameter groups specified in details section. |
parm.group.check |
A logical of whether or not to use NWIS parameter groups. If TRUE, must use NWIS parameter group names in dl.parms |
begin.date |
Character string containing beginning date of data pull (yyyy-mm-dd) |
end.date |
Character string containing ending date of data pull (yyyy-mm-dd) |
projectCd |
Character vector containing project codes to subset data by. |
resultAsText |
Output results as character instead of numeric. Used for literal output of results from NWIS that are no affected by class coerrcion, such as dropping zeros after decimal point. Default is False. |
NWIS parameter groups are as follows: All = "All", physical = "PHY", cations = "INM", anions = "INN", nutrients = "NUT", microbiological = "MBI", biological = "BIO", metals = "IMM", nonmetals = "IMN", pesticides = "TOX", pcbs="OPE", other organics = "OPC", radio chemicals = "RAD", stable isotopes = "XXX", sediment = "SED", population/community = "POP"
Returns a list containing two dataframes: PlotTable and DataTable. PlotTable contains all data pulled from NWIS along with all assosciated metadata in by-result format. DataTable contains all data pulled from NWIS in wide (sample-result) format, an easier format for import into spreadsheet programs. Dataframe names will be changed to more appropriate values in future package updates.
1 2 3 4 5 6 7 8 9 10 11 12 13 | ## Not run:
#Will not run unless connected to NWISCO
qw.data <- readNWISodbc(DSN="NWISCO",
env.db = "01",
qa.db = "02",
STAIDS = c("06733000","09067005"),
dl.parms="All",
parm.group.check=TRUE,
begin.date = "2005-01-01",
end.date = "2015-10-27",
projectCd = NULL)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.