Package: dataRetrieval 2.7.16.1

Laura DeCicco

dataRetrieval: Retrieval Functions for USGS and EPA Hydrology and Water Quality Data

Collection of functions to help retrieve U.S. Geological Survey and U.S. Environmental Protection Agency water quality and hydrology data from web services. Data are discovered from National Water Information System <https://waterservices.usgs.gov/> and <https://waterdata.usgs.gov/nwis>. Water quality data are obtained from the Water Quality Portal <https://www.waterqualitydata.us/>.

Authors:Laura DeCicco [aut, cre], Robert Hirsch [aut], David Lorenz [aut], Jordan Read [ctb], Jordan Walker [ctb], Lindsay Platt [ctb], David Watkins [aut], David Blodgett [aut], Mike Johnson [aut], Aliesha Krall [ctb]

dataRetrieval_2.7.16.1.tar.gz
dataRetrieval_2.7.16.1.zip(r-4.5)dataRetrieval_2.7.16.1.zip(r-4.4)dataRetrieval_2.7.16.1.zip(r-4.3)
dataRetrieval_2.7.16.1.tgz(r-4.4-any)dataRetrieval_2.7.16.1.tgz(r-4.3-any)
dataRetrieval_2.7.16.1.tar.gz(r-4.5-noble)dataRetrieval_2.7.16.1.tar.gz(r-4.4-noble)
dataRetrieval_2.7.16.1.tgz(r-4.4-emscripten)dataRetrieval_2.7.16.1.tgz(r-4.3-emscripten)
dataRetrieval.pdf |dataRetrieval.html
dataRetrieval/json (API)
NEWS

# Install 'dataRetrieval' in R:
install.packages('dataRetrieval', repos = c('https://doi-usgs.r-universe.dev', 'https://cloud.r-project.org'))

Peer review:

Bug tracker:https://github.com/doi-usgs/dataretrieval/issues

On CRAN:

usgs

53 exports 260 stars 13.97 score 36 dependencies 12 dependents 3 mentions 1.8k scripts 4.1k downloads

Last updated 5 days agofrom:adfb21e921. Checks:OK: 7. Indexed: yes.

TargetResultDate
Doc / VignettesOKOct 08 2024
R-4.5-winOKOct 08 2024
R-4.5-linuxOKOct 08 2024
R-4.4-winOKOct 08 2024
R-4.4-macOKOct 08 2024
R-4.3-winOKOct 08 2024
R-4.3-macOKOct 08 2024

Exports:addWaterYearcalcWaterYearcheckWQPdatesconstructNWISURLconstructUseURLconstructWQPURLcountyCdcountyCdLookupcreate_NWIS_bibcreate_WQP_bibfindNLDIget_nldi_sourcesgetWebServiceDataimportNGWMNimportRDB1importWaterML1importWaterML2importWQPis_dataRetrieval_userparameterCdFileparse_WQPpcode_to_namepCodeToNamereadNGWMNdatareadNGWMNlevelsreadNGWMNsitesreadNWISdatareadNWISdvreadNWISgwlreadNWISmeasreadNWISpCodereadNWISpeakreadNWISqwreadNWISratingreadNWISsitereadNWISstatreadNWISusereadNWISuvreadWQPdatareadWQPqwreadWQPsummaryrenameNWISColumnssetAccessstateCdstateCdLookupwhatNWISdatawhatNWISsiteswhatWQPdatawhatWQPmetricswhatWQPsampleswhatWQPsiteswqp_check_statuszeroPad

Dependencies:askpassbitbit64clicliprcpp11crayoncurlfansigenericsgluehmshttrjsonlitelifecyclelubridatemagrittrmimeopensslpillarpkgconfigprettyunitsprogressR6readrrlangsystibbletidyselecttimechangetzdbutf8vctrsvroomwithrxml2

Changes to NWIS QW services

Rendered fromqwdata_changes.Rmdusingknitr::rmarkdownon Oct 08 2024.

Last update: 2024-07-10
Started: 2021-07-29

Introduction to the dataRetrieval package

Rendered fromdataRetrieval.Rmdusingknitr::rmarkdownon Oct 08 2024.

Last update: 2024-07-24
Started: 2017-05-19

Readme and manuals

Help Manual

Help pageTopics
add a water year columnaddWaterYear
Extract WY from a datecalcWaterYear
Date Check for Water Quality PortalcheckWQPdates
Construct NWIS url for data retrievalconstructNWISURL
Construct URL for NWIS water use data serviceconstructUseURL
Construct WQP url for data retrievalconstructWQPURL
US County Code Lookup TablecountyCd
County code look upcountyCdLookup
Create NWIS data citationcreate_NWIS_bib
Create WQP data citationcreate_WQP_bib
R Client for the Network Linked Data IndexfindNLDI
Get current NLDI offeringsget_nldi_sources
getting header information from a WQP querygetQuerySummary
Function to return data from web servicesgetWebServiceData
Function to return data from the National Ground Water Monitoring Network waterML2 formatimportNGWMN
Function to return data from the NWIS RDB 1.0 formatimportRDB1
Function to return data from the NWISWeb WaterML1.1 serviceimportWaterML1
Parse the WaterML2 timeseries portion of a waterML2 fileimportWaterML2
Basic Water Quality Portal Data parserimportWQP
Is this a dataRetrieval useris_dataRetrieval_user
List of USGS parameter codesparameterCdFile
Convert WQP columns to correct typesparse_WQP
Parameter code to characteristic namepcode_to_name
Import data from the National Groundwater Monitoring Network <https://cida.usgs.gov/ngwmn/>.readNGWMNdata
Retrieve groundwater levels from the National Ground Water Monitoring Network <https://cida.usgs.gov/ngwmn/>.readNGWMNlevels
Retrieve site data from the National Ground Water Monitoring Network <https://cida.usgs.gov/ngwmn/>.readNGWMNsites
General Data Import from NWISreadNWISdata
Daily Value USGS NWIS Data RetrievalreadNWISdv
Groundwater level measurements retrieval from USGS (NWIS)readNWISgwl
Surface-water measurement data retrieval from USGS (NWIS)readNWISmeas
USGS Parameter Data RetrievalreadNWISpCode
Peak flow data from USGS (NWIS)readNWISpeak
Raw Data Import for USGS NWIS QW DatareadNWISqw
Rating table for an active USGS streamgage retrievalreadNWISrating
USGS Site File Data RetrievalreadNWISsite
Site statistics retrieval from USGS (NWIS)readNWISstat
Water use data retrieval from USGS (NWIS)readNWISuse
Instantaneous value data retrieval from USGS (NWIS)readNWISuv
General Data Import from Water Quality PortalreadWQPdata
Raw Data Import for Water Quality PortalreadWQPqw
Summary of Data Available from Water Quality PortalreadWQPsummary
renameColumnsrenameNWISColumns
Set data endpointsetAccess
US State Code Lookup TablestateCd
State code look upstateCdLookup
USGS data availabilitywhatNWISdata
Site Data Import from NWISwhatNWISsites
Data Available from Water Quality PortalwhatWQPdata
Site Data Import from Water Quality PortalwhatWQPmetrics whatWQPsamples whatWQPsites
Get WQP service metadatawqp_check_status
Pad string with leading zeroszeroPad