USEPA / EPATADA

This R package can be used to compile and evaluate Water Quality Portal (WQP) data for samples collected from surface water monitoring sites on streams and lakes. It can be used to create applications that support water quality programs and help states, tribes, and other stakeholders efficiently analyze the data.
https://usepa.github.io/EPATADA/
Creative Commons Zero v1.0 Universal
39 stars 18 forks source link

Advanced data retrieval #222

Open cristinamullin opened 1 year ago

cristinamullin commented 1 year ago

Users would like to retrieve WQP data and OPTIONALLY any additional USGS continuous data that in the specific area of interest and possible also nearby data (within additional buffer zone) or upstream/downstream as well (not just within the bounding box).

We can bring in USGS continuous data via dataRetrieval. We can also leverage NLDI to query by lat/long (e.g. all sites within 500m). Only problem is that for the continuous data, USGS uses p-codes and not Characteristic Names, so it may be best to wait until after this year (they are working on moving away from p-codes).

Example code: advancedqueries.zip

Which is best - NLDI or nhdplusTools to retrieve catchment geometries in R/ discover nearby data from other data sources?

jbousquin commented 1 year ago

Yes on continuous data. For NLDI could you leverage existing R tools, like nhdplusTools in more of a couple short demo?

cristinamullin commented 10 months ago

Note from Shelly: Consider how the NLDI use case would be done with WATERS. NLDI and WATERS both use a manual process to index WQP location to NHDPlus reach codes. NLDI is stored at USGS and WATERS is stored at EPA. NLDI and WATERS both index WQP locations to NHDPlus V2. WQP indexed locations to the WBD (HUC12s) not NHD or NHDPlus. If we wanted to bring in the USGS continuous data we may want to consider writing a TADA R function that leverages WATERS APIs and USGS continuous data APIs rather than leveraging dataRetreival (which includes the NLDI integration: https://github.com/DOI-USGS/dataRetrieval/blob/main/R/findNLDI.R). Needs more discussion!

cristinamullin commented 10 months ago

OP_Mapping_forEPA.txt Note that USGS migration from p-codes to observed properties may fix that compatibility issue between their cont data and their discrete data. Not sure if this migration to observed properties will cover NWIS cont data or only their discrete WQ data that already goes to WQP.