What is geoconnex.us? It is a framework for providers of water data to publish structured, linked metadata in a manner such that web crawlers can organize this metadata into a knowledge graph. This metadata should be formatted as JSON-LD. This knowledge graph can be leveraged to create a wide array of information products to answer innumerable water-related questions. This vignette serves as a mockup of what navigating through the Geoconnex knowledge graph might look like on build-out. Here, we use R as the primary way of interacting with a small proof-of-concept knowledge graph. However, on build-out, the complete graph will be published with Public Domain license, and will be free to use by anyone to create custom interfaces for humans and machines to meet many use cases.
The geoconnex.us framework includes a large and growing catalog of “community reference features” – neutral internet representations of real-world locations and areas that can be used by water data providers to describe what their published data is about. Many of these reference features are available from the website https://reference.geoconnex.us, which is powered by pygeoapi, a python implementation of OGC API-Features. This API enables programmatic interaction with spatial features on the web.
What’s available from https://reference.geoconnex.us? We have collated a variety of common hydrologic and administrative locations and boundaries, and will continue to add more.
collection_url <- "https://reference.geoconnex.us/collections"
collections <- jsonlite::fromJSON(collection_url)
knitr::kable(select(collections$collections, title, description))
title | description |
---|---|
HU02 | Two-digit Hydrologic Regions |
HU04 | Four-digit Hydrologic Subregion |
HU06 | Six-digit Hydrologic Basins |
HU08 | Eight-digit Hydrologic Subbasins |
HU10 | Ten-digit Watersheds |
National Aquifers | National Aquifers of the United States |
Reference Gages | US Reference Stream Gage Monitoring Locations |
States | U.S. States |
Counties | U.S. Counties |
American Indian/Alaska Native Areas/Hawaiian Home Lands (AIANNH) | Native American Lands |
Core-based statistical areas (CBSA) | U.S. Metropolitan and Micropolitan Statistical Areas |
Urban Areas | Urbanized Areas and Urban Clusters (2010 Census) |
Places | U.S. legally incororated and Census designated places |
Public Water Systems | U.S. Public Water Systems |
Let’s use New Mexico as our area of interest.
nm_url <- "https://reference.geoconnex.us/collections/states/items?STUSPS=NM"
nm <- sf::read_sf(nm_url)
mapview::mapview(list(`New Mexico` = convert(nm)))
The search above gave us one state that we can retrieve by its ID. Below, we grab its JSON-LD format, and print two versions of what can be interpreted, the raw JSON-LD and the “flattened” form that interprets the fields according to published linked data vocabularies such as https://schema.org.
accept_jsonld <- httr::add_headers("Accept" = "application/ld+json")
nm_ld <- rawToChar(httr::GET(nm$id, config = accept_jsonld)$content)
prettify(nm_ld)
## {
## "@context": [
## {
## "schema": "https://schema.org/",
## "geojson": "https://purl.org/geojson/vocab#",
## "Feature": "geojson:Feature",
## "FeatureCollection": "geojson:FeatureCollection",
## "Point": "geojson:Point",
## "bbox": {
## "@container": "@list",
## "@id": "geojson:bbox"
## },
## "coordinates": {
## "@container": "@list",
## "@id": "geojson:coordinates"
## },
## "features": {
## "@container": "@set",
## "@id": "geojson:features"
## },
## "geometry": "geojson:geometry",
## "id": "@id",
## "properties": "geojson:properties",
## "type": "@type"
## },
## {
## "schema": "https://schema.org/",
## "NAME": "schema:name",
## "census_profile": {
## "@id": "schema:subjectOf",
## "@type": "@id"
## }
## }
## ],
## "type": "Feature",
## "properties": {
## "fid": 14,
## "STATEFP": "35",
## "STATENS": "00897535",
## "AFFGEOID": "0400000US35",
## "GEOID": "35",
## "STUSPS": "NM",
## "NAME": "New Mexico",
## "LSAD": "00",
## "uri": "https://geoconnex.us/ref/states/35",
## "census_profile": "https://data.census.gov/cedsci/profile?g=0400000US35",
## "id": "https://geoconnex.us/ref/states/35"
## },
## "id": "https://geoconnex.us/ref/states/35"
## }
##
nm_ld <- jsonld::jsonld_flatten(nm_ld)
nm_ld
## [
## {
## "@id": "https://geoconnex.us/ref/states/35",
## "@type": [
## "https://purl.org/geojson/vocab#Feature"
## ],
## "https://purl.org/geojson/vocab#properties": [
## {
## "@id": "https://geoconnex.us/ref/states/35"
## }
## ],
## "https://schema.org/name": [
## {
## "@value": "New Mexico"
## }
## ],
## "https://schema.org/subjectOf": [
## {
## "@id": "https://data.census.gov/cedsci/profile?g=0400000US35"
## }
## ]
## }
## ]
nm_ld <- fromJSON(nm_ld)
This gives us some basic information. The @id
here is especially useful. Note that the @id
(the subject of all the triples in the document) is the same as the id
of the State GeoJSON we mapped above and used to retrieve this JSON-LD document. These @id
s are all in the form of HTTP URI (Uniform Resource Identifier), and should redirect to landing pages on the web.
Notice that we can get a name using a linked data property https://schema.org/name
here. This is an example of structured data that would allow automated creation of information products, a key aim of geoconnex.us.
nm_feature <- sf::read_sf(nm_ld$`@id`)
nm_feature_name <- nm_ld$`https://schema.org/name`[[1]]$`@value`
print(nm_feature_name)
## [1] "New Mexico"
Now let’s pivot to look at some data that might be of particular interest. Let’s say I’m most interested in Las Vegas, New Mexico. Where is this city, and what is its boundary? Let’s search for this place in the U.S. Census Places feature collection within NM (FIPS Code 35)
## nm
NM_places <- sf::read_sf("https://reference.geoconnex.us/collections/places/items?STATEFP=35&limit=10000000")
LasVegas <- filter(NM_places, NAME=="Las Vegas")
mapview::mapview(list("Las Vegas"=convert(LasVegas)))
print(LasVegas$uri)
## [1] "https://geoconnex.us/ref/places/3539940"
By printing the uri
, we can see the URI for the city of Las Vegas, NM. Now, what if I want to see which Public Water Systems (PWS) serve this city? Let’s see what Queryables the PWS reference features offer:
knitr::kable(fromJSON("https://reference.geoconnex.us/collections/pws/queryables"))
|
We can query by CITY_SERVED_uri
. Let’s try it.
LasVegasURI <- "https://geoconnex.us/ref/places/3539940"
LasVegas_PWS <- sf::read_sf(paste0("https://reference.geoconnex.us/collections/pws/items?CITY_SERVED_uri=",LasVegasURI))
list <- convert_L(list("Las Vegas PWS"=LasVegas_PWS,"Las Vegas"=LasVegas))
mapview::mapview(list("Las Vegas PWS"=convert(LasVegas_PWS),
"City of Las Vegas"=convert(LasVegas)), col.regions=c("blue","green"))
Clicking around, we can find what seems to be the main water provider, PWSID NM3518025 (@id
https://geoconnex.us/ref/pws/NM3518025). The embedded JSON-LD harvested includes a subjectOf
link to the USEPA Safe Drinking Water Information System (SDWIS), indicating that this EPA page is about this particular water system. As geoconnex.us expands and developed, every community reference feature such as this one should have many links that can direct us to all kinds of metadata and data published by other organizations that are relevant to the feature.
lv_pws_ld <- rawToChar(httr::GET("https://geoconnex.us/ref/pws/NM3518025", config = accept_jsonld)$content)
lv_pws_ld <- jsonld::jsonld_flatten(lv_pws_ld)
lv_pws_ld
## [
## {
## "@id": "https://geoconnex.us/ref/pws/NM3518025",
## "@type": [
## "https://purl.org/geojson/vocab#Feature"
## ],
## "https://purl.org/geojson/vocab#properties": [
## {
## "@id": "https://geoconnex.us/ref/pws/NM3518025"
## }
## ],
## "https://schema.org/geoIntersects": [
## {
## "@id": "https://geoconnex.us/ref/places/3539940"
## }
## ],
## "https://schema.org/geoWithin": [
## {
## "@id": "https://geoconnex.us/ref/states/35"
## }
## ],
## "https://schema.org/isBasedOn": [
## {
## "@id": "https://catalog.newmexicowaterdata.org/en/dataset/public-water-supply-areas"
## }
## ],
## "https://schema.org/name": [
## {
## "@value": "LAS VEGAS (CITY OF)\r\n"
## }
## ],
## "https://schema.org/subjectOf": [
## {
## "@id": "https://enviro.epa.gov/enviro/sdw_report_v3.first_table?pws_id=NM3518025&state=NM&source=Surface%20water&population=18044"
## }
## ]
## }
## ]
Now let’s find some more of this other data published by other organizations, not just the reference features. First, let’s widen our scope a bit. Let’s say we’re interested in water data that is in the same HUC8 as Las Vegas.
hu08_url <- paste0("https://reference.geoconnex.us/collections/hu08/items?bbox=",
paste(sf::st_bbox(nm_feature), collapse = ","))
hu08 <- sf::read_sf(hu08_url)
hu08 <- hu08[LasVegas,]
hu08$NAME
## [1] "Pecos Headwaters"
mapview::mapview(list("Pecos Headwaters" = convert(hu08),
"Las Vegas" = convert(LasVegas)),col.regions=c("green","blue"),alpha.regions=c(0.1,0.6))
Just working with spatial intersections from the HUC8 reference feature collection, we find the relevant HUC8 is the Pecos Headwaters. Now, we can make use of all data within the geoconnex.us system that has been published by all organizations. On build-out, we will be able to interact with a knowledge graph that is being continually updated by web crawlers that harvest JSON-LD from all participating provider websites. Parts of this knowledge graph, in turn, would be re-presented in the reference features JSON-LD. In this example, the JSON-LD from the page for the Pecos Headwaters (https://geoconnex.us/ref/hu08/13060001) might include links with the relationship label geoContains
for every water data site about a location within that HUC8. For this exercise, we will load a pre-processed list of dataframes with the same information.
Layers can be turned on and off with the layers button on the top left for greater readability. That’s a lot of data though!
load("graph.rds")
names(within_hu08_13060001)
## [1] "HUC8" "PWS"
## [3] "WaDE Sites" "NMED-SDWIS_Sample_Points"
## [5] "NMED-NPDES" "NMBGMR-Wells"
## [7] "Reference Gages"
t <- convert_L(within_hu08_13060001)
mapview::mapview(convert_L(within_hu08_13060001),
col.regions=c("green",
"blue",
"white",
"orange",
"red",
"black",
"violet"),
cex = c(3,
3,
4,
6,
6,
6,
6),
alpha.regions = c(0.1,
0.6,
0.9,
0.9,
0.9,
0.9,
0.9))
It looks like, in addition to the HUC8 and the PWS, we also have data from:
A key part of the philosophy of geoconnex is that metadata is published independently by organizations and harvested automatically. Hovering around these various features on the map, we can that all sites have a uri
(@id
) that begins with “https://geoconnex.us/”. However, if one follows these links, one is taken to different websites hosted on different servers by different organizations that are not aware of each other.
For example, https://geoconnex.us/nmwdi/nmbgmr/wells/WL-0183 redirects to http://wells.newmexicowaterdata.org/collections/nmbgmr_wells/items/WL-0183 , a pygeoapi instance operated by the New Mexico Water Data Initiative.
Meanwhile https://geoconnex.us/wade/sites/NM_146344 redirects to https://wade-test.geoconnex.us/collections/WaDE/items/NM_146344, a separate pygeoapi instance operated by the Water Data Exchange.
However, since both data systems provide JSON-LD markup, their metadata can be harvested automatically to create the data discovery workflow visualized here. This allows us to browse through the metadata. For example, perhaps we are only interested the SDWIS points and the NPDES permit for the Las Vegas drinking water system:
npdes <- within_hu08_13060001$`NMED-NPDES`
lv <- filter(within_hu08_13060001$PWS,
CITY_SERVED_uri == "https://geoconnex.us/ref/places/3539940")
lv <- st_as_sfc(st_bbox(lv))
npdes <- npdes[lv,]
lv <- filter(within_hu08_13060001$PWS,uri=="https://geoconnex.us/ref/pws/NM3518025")
sdwis <- filter(within_hu08_13060001$`NMED-SDWIS_Sample_Points`,
pws == "https://geoconnex.us/ref/pws/NM3518025")
mapview::mapview(list("Las Vegas PWS"=convert(lv))) +
mapview::mapview(list("Las Vegas SDWIS Sample Points"=convert(sdwis)), col.regions="orange") +
mapview::mapview(list("Las Vegas NPDES Points"=convert(npdes)), col.regions="red")
The true power of the system comes when organizations link data to the structured metadata they publish and that geoconnex.us can harvest. For example, the southernmost NPDES point (corresponding to the Las Vegas Wastewater Treatment Plant) includes linked data in the “sta” variable, referring to the OGC SensorThings API, at this URL: https://st.newmexicowaterdata.org/FROST-Server/v1.1/Things(2682)?$expand=Datastreams/Observations. Parsing the JSON response is simple. Thus, we can call the actual underlying data from NMED from the harvested metadata, learning that the Las Vegas Wastewater Treatment Plant has an NPDES permit that is effective as of May 01, 2017, and expires April 30, 2022.
data <- as.data.frame(fromJSON(npdes[2,]$sta)$Datastreams$Observations)
print('as.data.frame(fromJSON(npdes[2,]$sta)$Datastreams$Observations)')
## [1] "as.data.frame(fromJSON(npdes[2,]$sta)$Datastreams$Observations)"
knitr::kable(select(data,result,resultTime))
result | resultTime |
---|---|
expiration | 2022-04-30T00:00:00.000Z |
effective | 2017-05-01T00:00:00.000Z |
Above, we showed how a knowledge graph created by geoconnex can simplify searching for relevant data, relative to the status quo of needing to know about all of those data systems, and how to access their metadata separately. However, other complementary tools can be used alongside Geoconnex assets to further refine data discovery and access. Let’s say we’re interested in conditions directly downstream of the Las Vegas WWTP. We can use the USGS Network-Linked Data Index to discover relevant data in that system. We can use the WWTP (@id
https://geoconnex.us/nmwdi/nmbgmr/wells/NM0028827) as a starting point, and use the NLDI service to find the downstream mainstem.
geom_site <- sf::read_sf("https://geoconnex.us/nmwdi/nmbgmr/wells/NM0028827")
point <- sf::st_sfc(geom_site$geometry)
geom_site <- geom_site$geometry[[1]]
nldi_point<-nhdplusTools::discover_nhdplus_id(point)
# nldiURL<-"DM = "https://labs.waterdata.usgs.gov/api/nldi/linked-data/nwissite/USGS-08279500/navigate/DM?distance=100"
nldi_query <- URLencode(paste0('https://labs.waterdata.usgs.gov/api/nldi/linked-data/comid/position?f=json&coords=POINT(',geom_site[1],' ',geom_site[2],')'))
start <- sf::read_sf(nldi_query)
mainstem <- sf::read_sf(paste0(start$navigation,"/DM/flowlines?distance=250"))
mapview::mapview(list("Pecos Headwaters"=convert(within_hu08_13060001$HUC8)), col.regions=c("green"), alpha.regions=0.1) +
mapview::mapview(list("Las Vegas NPDES Points"=convert(npdes)), col.regions="red") + mapview::mapview(list("Las Vegas PWS"=convert(lv)), col.regions="black") +
mapview::mapview(list("Downstream Mainstem"=sf::st_as_sf(sf::st_geometry(mainstem)[within_hu08_13060001$HUC8,])), hcl.colors="blue")
The above code constructs the URLs to call the NLDI service directly, however there are convenience tools in R and Python to interact with the NLDI. Below we use the R package nhdplusTools
to discover data indexed to our downstream mainstem in the NLDI. What features are available from the NLDI?
knitr::kable(fromJSON("https://labs.waterdata.usgs.gov/api/nldi/linked-data"))
source | sourceName | features |
---|---|---|
comid | NHDPlus comid | https://labs.waterdata.usgs.gov/api/nldi/linked-data/comid |
huc12pp | HUC12 Pour Points | https://labs.waterdata.usgs.gov/api/nldi/linked-data/huc12pp |
nwissite | NWIS Sites | https://labs.waterdata.usgs.gov/api/nldi/linked-data/nwissite |
wade | Water Data Exchange 2.0 Sites | https://labs.waterdata.usgs.gov/api/nldi/linked-data/wade |
WQP | Water Quality Portal | https://labs.waterdata.usgs.gov/api/nldi/linked-data/wqp |
We can use the NLDI to find USGS National Water Information System (NWIS) Sites and WaDE sites (which are also available from the Reference Gages feature collection in reference.geoconnex.us and from WaDE itself from wade-test.geoconnex.us, respectively), as well as Water Quality Portal (WQP) Sites. In the future, any organizations interested in participating in Geoconnex should also consider adding their location metadata to the NLDI.
Rather than finding these sites from the knowledge graph about the Pecos Headwaters HUC8, below we use the NLDI to find only those sites that are indexed to the mainstem of the Pecos River downstream of the Las Vegas WWTP.
nldi_feature <- list(featureSource = "comid",
featureID = start$identifier)
wade <- nhdplusTools::navigate_nldi(nldi_feature, "DM", "wade", distance_km = 250)
wqp <- nhdplusTools::navigate_nldi(nldi_feature, "DM", "wqp", distance_km = 250)
nwis <- nhdplusTools::navigate_nldi(nldi_feature, "DM", "nwissite", distance_km = 250)
mapview::mapview(list("Pecos Headwaters"=convert(within_hu08_13060001$HUC8)), col.regions=c("green"), alpha.regions=0.1) +
mapview::mapview(list("Las Vegas NPDES Points"=convert(npdes)), col.regions="red") + mapview::mapview(list("Las Vegas PWS"=convert(lv)), col.regions="black") +
mapview::mapview(list("Downstream Mainstem"=sf::st_as_sf(sf::st_geometry(mainstem)[within_hu08_13060001$HUC8,])), hcl.colors="blue") +
mapview::mapview(list(
"WaDE Sites" = convert(wade),
"WQP Sites" = convert(wqp),
"NWIS SItes" = convert(nwis)),
col.regions = c("white","orange","darkgreen")
)
map <- mapview::mapview(list("Pecos Headwaters"=convert(within_hu08_13060001$HUC8)), col.regions=c("green"), alpha.regions=0.1) +
mapview::mapview(list("Las Vegas NPDES Points"=convert(npdes)), col.regions="red") + mapview::mapview(list("Las Vegas PWS"=convert(lv)), col.regions="black") +
mapview::mapview(list("Downstream Mainstem"=sf::st_as_sf(sf::st_geometry(mainstem)[within_hu08_13060001$HUC8,])), hcl.colors="blue") +
mapview::mapview(list(
"WaDE Sites" = convert(wade),
"WQP Sites" = convert(wqp),
"NWIS SItes" = convert(nwis)),
col.regions = c("white","orange","darkgreen")
)
Let’s zoom in to the area around San Augustin, NM. Just to demonstrate an additional piece of information available from Geoconnex, let’s use the geoconnex.us identifier for NHDPlusV2 COMID 20815744
san <- sf::read_sf("https://geoconnex.us/nhdplusv2/comid/20815744")
san <- sf::st_centroid(san)
x <- san$geometry[[1]][1]
y <- san$geometry[[1]][2]
map@map %>% leaflet::setView(lng=x, lat=y, zoom=14)
Browsing around some of the sites available, we see a few:
We can use both linked metadata and API clients to get data from these sites we have discovered using Geoconnex and the NLDI.
For example, we can harvest JSON-LD metadata from the NWIS site:
nwis_url <- "https://waterdata.usgs.gov/monitoring-location/08382000"
nwis_ld <- rawToChar(httr::GET(nwis_url, config = accept_jsonld)$content)
prettify(nwis_ld)
## {
## "@context": [
## "https://opengeospatial.github.io/ELFIE/json-ld/elf-index.jsonld",
## "https://opengeospatial.github.io/ELFIE/json-ld/hyf.jsonld"
## ],
## "@id": "https://waterdata.usgs.gov/monitoring-location/08382000",
## "@type": "http://www.opengeospatial.org/standards/waterml2/hy_features/HY_HydroLocation",
## "name": "GALLINAS RIVER NEAR LOURDES, NM",
## "sameAs": "https://waterdata.usgs.gov/nwis/inventory/?site_no=08382000",
## "HY_HydroLocationType": "hydrometricStation",
## "geo": {
## "@type": "schema:GeoCoordinates",
## "latitude": "35.46890278",
## "longitude": "-105.1614417"
## },
## "image": "https://waterdata.usgs.gov/nwisweb/graph?agency_cd=USGS&site_no=08382000&parm_cd=00060&period=100"
## }
##
nwis_metadata <- fromJSON(nwis_ld)
Note the linked data for "image:"
, which denotes an instance of https://schema.org/image. Accessing this item:
We can use the DataRetrieval
package to access data from the Water Quality Portal site:
WQPsite <- dataRetrieval::readWQPdata(siteid="21NMEX-50GALLIN075.0",
characteristicName="Manganese")
timetk::plot_time_series(WQPsite,
ActivityStartDate,
ResultMeasureValue,
.title = "Manganese Measurements (mg/l) by NMED at 21NMEX-50GALLIN075.0",
.x_lab = "Date",
.y_lab = "Manganese Sample Concentration (mg/l)",
.smooth = FALSE)
We can follow the geoconnex
based identifier for the WaDE site, and parse the JSON-LD embedded in that site:
wade_url <- "https://geoconnex.us/wade/sites/NM_98417"
wade_ld <- rawToChar(httr::GET(wade_url, config = accept_jsonld)$content)
jsonld::jsonld_flatten(wade_ld)
## [
## {
## "@id": "_:b0",
## "@type": [
## "https://purl.org/geojson/vocab#Feature"
## ],
## "https://purl.org/geojson/vocab#geometry": [
## {
## "@id": "_:b1"
## }
## ],
## "https://purl.org/geojson/vocab#properties": [
## {
## "@id": "https://geoconnex.us/wade/sites/NM_98417"
## }
## ],
## "https://schema.org/name": [
## {
## "@value": "https://geoconnex.us/wade/sites/NM_98417"
## }
## ]
## },
## {
## "@id": "_:b1",
## "@type": [
## "https://purl.org/geojson/vocab#Point"
## ],
## "https://purl.org/geojson/vocab#coordinates": [
## {
## "@list": [
## {
## "@value": -105.1454023999999
## },
## {
## "@value": 35.45224047
## }
## ]
## }
## ]
## },
## {
## "@id": "https://geoconnex.us/wade/sites/NM_98417",
## "https://schema.org/name": [
## {
## "@value": "https://geoconnex.us/wade/sites/NM_98417"
## }
## ],
## "https://schema.org/url": [
## {
## "@value": "https://wade-api-qa.azure-api.net/v1/SiteAllocationAmounts?SiteUUID=NM_98417"
## }
## ]
## }
## ]
wade_metadata <- fromJSON(jsonld::jsonld_flatten(wade_ld))
Note the linked data for "https://schema.org/url":
, which denotes an external link. In this case, the link is to the WaDE 2.0 API Call. Note that the WaDE 2.0 API is only available on an experimental basis and all data is provisional. Parsing the JSON response from that call, we receive a rich amount of information about the water right associated with the point of diversion originating from the New Mexico Office of the State Engineer and organized by WaDE. Below, we display some information available from the API, such as the name of the originating organization, and the Beneficial Uses associated with the site
prettify(readLines(wade_metadata$`https://schema.org/url`[[3]]$`@value`))
## {
## "TotalWaterAllocationsCount": 1,
## "Organizations": [
## {
## "OrganizationName": "New Mexico Office of the State Engineer�",
## "OrganizationPurview": "�The New Mexico Office of the State Engineer (OSE) provides this geographic data and any associated metadata �as is� without warranty of any kind",
## "OrganizationWebsite": "https://github.com/WSWCWaterDataExchange/MappingStatesDataToWaDE2.0/tree/master/NewMexico",
## "OrganizationPhoneNumber": "303-866-3581",
## "OrganizationContactName": "Rebecca Mitchell",
## "OrganizationContactEmail": "abc@co.com",
## "OrganizationState": "NM",
## "WaterSources": [
## {
## "WaterSourceName": "Unknown",
## "WaterSourceNativeID": "0",
## "WaterSourceUUID": "NM_1",
## "WaterSourceTypeCV": "Groundwater",
## "FreshSalineIndicatorCV": "Fresh",
## "WaterSourceGeometry": null
## }
## ],
## "VariableSpecifics": [
## {
## "VariableSpecificTypeCV": "Allocation All",
## "VariableCV": "Allocation",
## "AmountUnitCV": "CFS",
## "AggregationStatisticCV": "Average",
## "AggregationInterval": "1.0",
## "AggregationIntervalUnitCV": "Year",
## "ReportYearStartMonth": "10",
## "ReportYearTypeCV": "WaterYear",
## "MaximumAmountUnitCV": "AFY"
## }
## ],
## "Methods": [
## {
## "MethodUUID": "NMOSE_Water Allocation",
## "MethodName": "Water Allocation",
## "MethodDescription": "Water Rights",
## "MethodNEMILink": "http://geospatialdata-ose.opendata.arcgis.com/search?groupIds=fabf18d6e0634ae38c86475c9ad a6498",
## "ApplicableResourceType": "Surface Ground",
## "MethodTypeCV": "Adjudicated",
## "DataCoverageValue": null,
## "DataQualityValue": null,
## "DataConfidenceValue": null
## }
## ],
## "BeneficialUses": [
## {
## "Term": "SAN",
## "State": "NM",
## "Definition": "",
## "Name": "72-12-1 Sanitary in conjunction with a commercial use",
## "SourceVocabularyURI": "",
## "USGSCategory": null,
## "NAICSCode": null
## }
## ],
## "WaterAllocations": [
## {
## "AllocationNativeID": "49405",
## "WaterSourceUUID": "NM_1",
## "AllocationOwner": "DEGEER INC,DAVID L",
## "AllocationApplicationDate": null,
## "AllocationPriorityDate": "1988-07-07T00:00:00",
## "AllocationLegalStatusCodeCV": "Permit",
## "AllocationExpirationDate": null,
## "AllocationChangeApplicationIndicator": null,
## "LegacyAllocationIDs": null,
## "AllocationAcreage": null,
## "AllocationBasisCV": "Unknown",
## "TimeframeStart": null,
## "TimeframeEnd": null,
## "DataPublicationDate": "2020-05-11T00:00:00",
## "AllocationCropDutyAmount": null,
## "AllocationFlow_CFS": -999.0,
## "AllocationVolume_AF": 0.0,
## "PopulationServed": null,
## "GeneratedPowerCapacityMW": null,
## "AllocationCommunityWaterSupplySystem": null,
## "AllocationSDWISIdentifier": null,
## "MethodUUID": "NMOSE_Water Allocation",
## "VariableSpecificTypeCV": "Allocation All",
## "Sites": [
## {
## "NativeSiteID": "49405",
## "Longitude": -106.64803863020828,
## "Latitude": 35.041285067037414,
## "SiteGeometry": null,
## "CoordinateMethodCV": "Unspecified",
## "AllocationGNISIDCV": null,
## "HUC8": null,
## "HUC12": null,
## "County": "BE",
## "PODorPOUSite": "POD"
## }
## ],
## "BeneficialUses": [
## "72-12-1 Sanitary in conjunction with a commercial use"
## ],
## "ExemptOfVolumeFlowPriority": false
## }
## ]
## }
## ]
## }
##
x <- fromJSON(readLines(wade_metadata$`https://schema.org/url`[[3]]$`@value`),flatten=TRUE)
x$Organizations$OrganizationName
## [1] "New Mexico Office of the State Engineer�"
knitr::kable(x$Organizations$BeneficialUses)
|
In this demo, we have explored how Geoconnex (the combination of reference features and independent organizational metadata published as JSON-LD embedded in site-level landing pages with persistent geoconnex.us/
-based identifiers), and complementary APIs such as the NLDI, NWIS Web, the Water Quality Portal, WaDE, and the OGC SensorThings API can be used to discover and access a large variety of water data. The value of Geoconnex will rise with the amount of metadata cataloged, so we are always recruiting for more organizations to participate! To learn more, please visit https://geoconnex.us and/or reach out to the authors, whose email addresses are below.
USGS, dblodgett@usgs.gov↩︎
Internet of Water, kyle.onda@duke.edu↩︎