QuerySiteData: Returns the data for given sites from local database.

Description Usage Arguments Value See Also Examples

View source: R/usgs_ingest.R

Description

QuerySiteData gets the specified data from the local database in long format.

Usage

1
2
QuerySiteData(site, product, path = ".",
  metaDBFileName = "usgsDataRetrieval.metaDatabase.RData")

Arguments

site

Character USGS site number or vector of numbers.

product

Character USGS product code number.

path

Character path to the database.

metaDBFileName

Character The name of the metadata file.

Value

dataframe of data with pertinent attributes.

See Also

Other streamObs: FindUsgsStns, GetSiteHuc, GetUsgsHucData, GetUsgsIvProduct, ImproveHucMeta, LoadMetaDB, PlotPrettyUsgs, PrettyUsgs, QueryHaveSite, QuerySiteInfo, QuerySiteName, QuerySiteProd, SaveHucData, [.prettyUsgs, subset.prettyUsgs

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
## Not run: 
p='~/wrfHydroTestCases/usgsDb/'
dataOrodell <- QuerySiteData(QuerySiteName("FOURMILE CREEK AT ORODELL, CO", p), 
                             '00060', p)
siteInfo<-QuerySiteInfo(c('station_nm','site_no','stateCd'), path=p)
dataCO <- QuerySiteData(subset(siteInfo, stateCd=='08' & product=='00060')$site_no,
                        '00060', p)
dataMultiHuc <- QuerySiteData(c('06730500','02084557'),'00060',p)
Case with ill-defined variables
dataMultiHuc <- QuerySiteData('06730500','00065',p)
## This is the multisite multi product case.
dataMultiHuc <- QuerySiteData(c('06730500','02084557'),c('00065','00060'),p)

## End(Not run)

mccreigh/rwrfhydro documentation built on May 12, 2018, 3:08 a.m.