{
  "type": "Collection",
  "stac_version": "1.1.0",
  "stac_extensions": [
    "https://stac-extensions.github.io/table/v1.2.0/schema.json",
    "https://stac-extensions.github.io/scientific/v1.0.0/schema.json"
  ],
  "id": "cwb-beach-water-quality",
  "title": "Hawaiʻi Beach Water Quality (Clean Water Branch, 1973–2024)",
  "description": "Beach water quality samples collected by the Hawaiʻi Department of Health Clean Water Branch (CWB) at 473 shoreline locations across the main Hawaiian Islands, from June 1973 to June 2024. The CWB monitors Enterococcus, the indicator bacterium for sewage-contaminated recreational water, and Clostridium perfringens as a secondary sewage tracer; some samples also carry water temperature, salinity, turbidity, pH and dissolved oxygen.\n\n**Two tables.** `samples` holds every sample (122,729 rows, one per sample, all upstream columns). The site layer (GeoParquet, PMTiles and hex) holds one point per `location_id` with sample counts and the first and last sample date. Join them on `location_id`.\n\n**What the record is good for.** Enterococcus is the populated measurement (93% of samples). The other parameters are often missing and sampling is irregular, roughly weekly to monthly at a site, so this is a per-visit indicator record, not a continuous time series. 37,556 samples predate 2000; 20,198 fall in 2013–2019. Upstream declares no end date, but the most recent sample at access was 2024-06-13.\n\n**Data quality.** Several water-chemistry columns contain values that are not physically plausible (zeros, and maxima such as pH 813 or salinity 3,635); each column description gives the counts and a filter. A location can appear under more than one name or position over the record; the site layer shows the most recent and counts the alternatives.\n\n**Licence.** Distributed by PacIOOS under the statement: \"The data may be used and redistributed for free but is not intended for legal use, since it may contain inaccuracies. Neither the data Contributor, University of Hawaii, PacIOOS, NOAA, State of Hawaii nor the United States Government, nor any of their employees or contractors, makes any warranty, express or implied, including warranties of merchantability and fitness for a particular purpose, or assumes any legal liability for the accuracy, completeness, or usefulness, of this information.\" PacIOOS publishes no separate terms page; the statement is the `license` attribute on the dataset's ERDDAP information page, which the licence link points to.\n\n**Provenance.** Pulled in full from PacIOOS ERDDAP dataset `cwb_water_quality` on 2026-11-02 (no edition label upstream). Staged copy: `s3://public-hawaii/raw/cwb-beach-water-quality/cwb_water_quality.csv.gz` (2,831,110 bytes, sha256 75f5a5f5527e5eeac1de169872dba3ece9ecad5c91dbfd7270632bd55911246f), with the ERDDAP metadata in `erddap-info.csv`. No exact duplicate rows were found.",
  "license": "other",
  "keywords": [
    "Hawaii",
    "water quality",
    "Enterococcus",
    "beach monitoring",
    "sewage",
    "PacIOOS",
    "HI-GLEN"
  ],
  "providers": [
    {
      "name": "Hawaiʻi Department of Health, Clean Water Branch",
      "roles": [
        "producer",
        "licensor"
      ],
      "url": "https://health.hawaii.gov/cwb/"
    },
    {
      "name": "Pacific Islands Ocean Observing System (PacIOOS)",
      "url": "https://www.pacioos.hawaii.edu/"
    },
    {
      "name": "Boettiger Lab",
      "roles": [
        "processor",
        "host"
      ],
      "url": "https://github.com/boettiger-lab/data-workflows"
    }
  ],
  "sci:citation": "State of Hawaii Department of Health, Clean Water Branch. Hawaii Clean Water Branch (CWB) Beach Water Quality Data. Distributed by the Pacific Islands Ocean Observing System (PacIOOS), ERDDAP dataset cwb_water_quality. Accessed 2026-11-02 from https://pae-paha.pacioos.hawaii.edu/erddap/tabledap/cwb_water_quality.html",
  "created": "2026-11-02T04:51:20Z",
  "updated": "2026-11-02T04:54:51Z",
  "extent": {
    "spatial": {
      "bbox": [
        [
          -159.77742,
          18.914389,
          -154.81667,
          22.225416
        ]
      ]
    },
    "temporal": {
      "interval": [
        [
          "1973-06-04T21:00:00Z",
          "2024-06-13T22:10:00Z"
        ]
      ]
    }
  },
  "links": [
    {
      "rel": "self",
      "href": "https://s3-west.nrp-nautilus.io/public-hawaii/cwb-beach-water-quality/stac-collection.json",
      "type": "application/json"
    },
    {
      "rel": "root",
      "href": "https://s3-west.nrp-nautilus.io/public-data/stac/catalog.json",
      "type": "application/json"
    },
    {
      "rel": "parent",
      "href": "https://s3-west.nrp-nautilus.io/public-hawaii/stac-collection.json",
      "type": "application/json"
    },
    {
      "rel": "describedby",
      "href": "https://s3-west.nrp-nautilus.io/public-hawaii/cwb-beach-water-quality/README.md",
      "type": "text/markdown"
    },
    {
      "rel": "about",
      "href": "https://pae-paha.pacioos.hawaii.edu/erddap/info/cwb_water_quality/index.html",
      "type": "text/html",
      "title": "PacIOOS ERDDAP: cwb_water_quality (metadata)"
    },
    {
      "rel": "via",
      "href": "https://pae-paha.pacioos.hawaii.edu/erddap/tabledap/cwb_water_quality.html",
      "type": "text/html",
      "title": "PacIOOS ERDDAP tabledap access form"
    },
    {
      "rel": "license",
      "href": "https://pae-paha.pacioos.hawaii.edu/erddap/info/cwb_water_quality/index.html",
      "type": "text/html",
      "title": "PacIOOS ERDDAP dataset information, license attribute (free use and redistribution, no warranty)"
    },
    {
      "rel": "pmtiles",
      "href": "https://s3-west.nrp-nautilus.io/public-hawaii/cwb-beach-water-quality.pmtiles",
      "type": "application/vnd.pmtiles",
      "title": "PMTiles vector tiles of sampling locations",
      "pmtiles:layers": [
        "cwb-beach-water-quality"
      ]
    },
    {
      "rel": "agents",
      "href": "./AGENTS.md",
      "type": "text/markdown",
      "title": "Agent guide"
    }
  ],
  "assets": {
    "cwb-beach-water-quality-samples": {
      "href": "https://s3-west.nrp-nautilus.io/public-hawaii/cwb-beach-water-quality/samples.parquet",
      "type": "application/vnd.apache.parquet",
      "title": "Samples: every water sample, 1973–2024 (non-spatial table)",
      "roles": [
        "data"
      ],
      "created": "2026-11-02T04:51:20Z",
      "description": "One row per water sample (122,729 rows), all upstream columns, sorted by location_id and time. Name and coordinates are as recorded on each sample. Join to the site layer on location_id.",
      "table:columns": [
        {
          "name": "time",
          "type": "timestamp"
        },
        {
          "name": "longitude",
          "type": "double"
        },
        {
          "name": "latitude",
          "type": "double"
        },
        {
          "name": "location_id",
          "type": "int32"
        },
        {
          "name": "location_name",
          "type": "string"
        },
        {
          "name": "enterococcus",
          "type": "double"
        },
        {
          "name": "clostridium",
          "type": "double"
        },
        {
          "name": "water_temperature",
          "type": "double"
        },
        {
          "name": "salinity",
          "type": "double"
        },
        {
          "name": "turbidity",
          "type": "double"
        },
        {
          "name": "ph",
          "type": "double"
        },
        {
          "name": "oxygen",
          "type": "double"
        },
        {
          "name": "oxygen_saturation",
          "type": "double"
        }
      ]
    },
    "cwb-beach-water-quality-parquet": {
      "href": "https://s3-west.nrp-nautilus.io/public-hawaii/cwb-beach-water-quality.parquet",
      "type": "application/vnd.apache.parquet",
      "title": "GeoParquet: 473 sampling locations",
      "roles": [
        "data"
      ],
      "created": "2026-11-02T04:53:17Z",
      "description": "One point per sampling location (location_id) with sample counts and first and last sample dates. Name and coordinates are those of the location's most recent sample; 42 locations were recorded under more than one name and 54 at more than one position over the record (n_names, n_positions).",
      "table:columns": [
        {
          "name": "_cng_fid",
          "type": "int64"
        },
        {
          "name": "location_id",
          "type": "int32"
        },
        {
          "name": "location_name",
          "type": "string"
        },
        {
          "name": "latitude",
          "type": "double"
        },
        {
          "name": "longitude",
          "type": "double"
        },
        {
          "name": "n_names",
          "type": "int64"
        },
        {
          "name": "n_positions",
          "type": "int64"
        },
        {
          "name": "n_samples",
          "type": "int64"
        },
        {
          "name": "first_sample",
          "type": "timestamp"
        },
        {
          "name": "last_sample",
          "type": "timestamp"
        },
        {
          "name": "n_enterococcus",
          "type": "int64"
        },
        {
          "name": "n_clostridium",
          "type": "int64"
        },
        {
          "name": "n_water_temperature",
          "type": "int64"
        },
        {
          "name": "n_salinity",
          "type": "int64"
        },
        {
          "name": "n_turbidity",
          "type": "int64"
        },
        {
          "name": "n_ph",
          "type": "int64"
        },
        {
          "name": "n_oxygen",
          "type": "int64"
        },
        {
          "name": "n_oxygen_saturation",
          "type": "int64"
        },
        {
          "name": "geometry",
          "type": "geometry"
        }
      ]
    },
    "cwb-beach-water-quality-pmtiles": {
      "href": "https://s3-west.nrp-nautilus.io/public-hawaii/cwb-beach-water-quality.pmtiles",
      "type": "application/vnd.pmtiles",
      "title": "PMTiles vector tiles of sampling locations",
      "roles": [
        "visual"
      ],
      "created": "2026-11-02T04:53:46Z",
      "description": "Vector tiles of the sampling locations for web maps. MapLibre source-layer name: 'cwb-beach-water-quality'.",
      "vector:layers": [
        "cwb-beach-water-quality"
      ],
      "table:columns": [
        {
          "name": "_cng_fid",
          "type": "number"
        },
        {
          "name": "location_id",
          "type": "number"
        },
        {
          "name": "location_name",
          "type": "string"
        },
        {
          "name": "latitude",
          "type": "number"
        },
        {
          "name": "longitude",
          "type": "number"
        },
        {
          "name": "n_names",
          "type": "number"
        },
        {
          "name": "n_positions",
          "type": "number"
        },
        {
          "name": "n_samples",
          "type": "number"
        },
        {
          "name": "first_sample",
          "type": "string"
        },
        {
          "name": "last_sample",
          "type": "string"
        },
        {
          "name": "n_enterococcus",
          "type": "number"
        },
        {
          "name": "n_clostridium",
          "type": "number"
        },
        {
          "name": "n_water_temperature",
          "type": "number"
        },
        {
          "name": "n_salinity",
          "type": "number"
        },
        {
          "name": "n_turbidity",
          "type": "number"
        },
        {
          "name": "n_ph",
          "type": "number"
        },
        {
          "name": "n_oxygen",
          "type": "number"
        },
        {
          "name": "n_oxygen_saturation",
          "type": "number"
        }
      ]
    },
    "cwb-beach-water-quality-hex": {
      "href": "https://s3-west.nrp-nautilus.io/public-hawaii/cwb-beach-water-quality/hex/h0=*/data_0.parquet",
      "type": "application/vnd.apache.parquet",
      "title": "H3 hexagonal index (resolution 8) of sampling locations",
      "roles": [
        "data"
      ],
      "created": "2026-11-02T04:54:51Z",
      "description": "H3 index of the 473 sampling locations at resolution 8 (each point falls in one cell of about 0.74 km²), hive-partitioned by h0. One row per location: a point covers a single cell, so per-location counts such as n_samples are not repeated across cells and can be summed directly. Several locations can share a cell (473 locations fall in 358 cells), so count locations with COUNT(DISTINCT _cng_fid), not by cells. This is a point dataset at resolution 8; it carries no finer resolution.",
      "h3:native_resolution": 8,
      "h3:parent_resolutions": [
        0
      ],
      "table:columns": [
        {
          "name": "_cng_fid",
          "type": "int64"
        },
        {
          "name": "location_id",
          "type": "int32"
        },
        {
          "name": "location_name",
          "type": "string"
        },
        {
          "name": "latitude",
          "type": "double"
        },
        {
          "name": "longitude",
          "type": "double"
        },
        {
          "name": "n_names",
          "type": "int64"
        },
        {
          "name": "n_positions",
          "type": "int64"
        },
        {
          "name": "n_samples",
          "type": "int64"
        },
        {
          "name": "first_sample",
          "type": "timestamp"
        },
        {
          "name": "last_sample",
          "type": "timestamp"
        },
        {
          "name": "n_enterococcus",
          "type": "int64"
        },
        {
          "name": "n_clostridium",
          "type": "int64"
        },
        {
          "name": "n_water_temperature",
          "type": "int64"
        },
        {
          "name": "n_salinity",
          "type": "int64"
        },
        {
          "name": "n_turbidity",
          "type": "int64"
        },
        {
          "name": "n_ph",
          "type": "int64"
        },
        {
          "name": "n_oxygen",
          "type": "int64"
        },
        {
          "name": "n_oxygen_saturation",
          "type": "int64"
        },
        {
          "name": "h8",
          "type": "uint64"
        },
        {
          "name": "h0",
          "type": "int64"
        }
      ]
    },
    "style-cwb-beach-water-quality-n-samples": {
      "href": "https://s3-west.nrp-nautilus.io/public-hawaii/cwb-beach-water-quality/styles/cwb-beach-water-quality-n-samples.json",
      "type": "application/vnd.mapbox.style+json",
      "title": "PMTiles vector tiles of sampling locations by number of samples",
      "description": "Features shaded by number of samples, in 6 classes at quantile breaks of the data. Each point is a sampling location, and the number of samples says how well it is monitored.",
      "roles": [
        "style",
        "default"
      ]
    },
    "thumbnail": {
      "href": "https://s3-west.nrp-nautilus.io/public-hawaii/cwb-beach-water-quality/thumbnail.png",
      "type": "image/png",
      "roles": [
        "thumbnail"
      ],
      "title": "Thumbnail",
      "description": "Preview drawn from the collection's default style style-cwb-beach-water-quality-n-samples."
    }
  },
  "table:columns": [
    {
      "name": "time",
      "type": "timestamp",
      "description": "Date and time the water sample was collected (UTC)."
    },
    {
      "name": "longitude",
      "type": "number",
      "description": "Longitude of the sampling location (decimal degrees, WGS 84)."
    },
    {
      "name": "latitude",
      "type": "number",
      "description": "Latitude of the sampling location (decimal degrees, WGS 84)."
    },
    {
      "name": "location_id",
      "type": "number",
      "description": "Clean Water Branch identifier for the sampling location. Joins the samples table to the site layer."
    },
    {
      "name": "location_name",
      "type": "string",
      "description": "Name of the sampling location. The same location_id can carry different names over the record (see n_names)."
    },
    {
      "name": "enterococcus",
      "type": "double",
      "description": "Enterococcus, colony-forming units per 100 mL. The beach-monitoring indicator bacterium; the most populated measurement (113,698 samples). Range 0 to 84,000."
    },
    {
      "name": "clostridium",
      "type": "double",
      "description": "Clostridium perfringens, colony-forming units per 100 mL. A secondary tracer of sewage contamination (93,041 samples). Range 0 to 2,000."
    },
    {
      "name": "water_temperature",
      "type": "double",
      "description": "Water temperature, °C (77,378 samples). 99% of values are at or below 30.3 °C; 24 samples record 0 and one records 2,638, which are not plausible sea temperatures. Filter to a plausible range (for example 15–35 °C) before averaging."
    },
    {
      "name": "salinity",
      "type": "double",
      "description": "Salinity, practical salinity units (95,614 samples). 99% of values are at or below 36; 174 samples record 0 and 4 exceed 45 (maximum 3,635). Low values can be real near stream mouths, so filter outliers rather than all low values."
    },
    {
      "name": "turbidity",
      "type": "double",
      "description": "Turbidity, nephelometric turbidity units (70,785 samples). Range 0 to 4,450; 99% of values are at or below 34.6."
    },
    {
      "name": "ph",
      "type": "double",
      "description": "pH (68,237 samples). 220 samples record 0 and 7 exceed 14 (maximum 813); neither is a valid pH. Filter to 0 < ph <= 14 before use."
    },
    {
      "name": "oxygen",
      "type": "double",
      "description": "Dissolved oxygen, mg/L (75,681 samples). 714 samples record 0, and 1,090 samples exceed 20 mg/L (99th percentile 88.6), which is not plausible for dissolved oxygen in mg/L; many of these look like percent saturation recorded in this column. Filter before use."
    },
    {
      "name": "oxygen_saturation",
      "type": "double",
      "description": "Dissolved oxygen saturation, percent (55,504 samples). Range 0 to 99.9; 714 samples record 0."
    },
    {
      "name": "_cng_fid",
      "type": "number",
      "description": "Feature identifier added during processing; one per row of the site layer. Unique per site, so COUNT(DISTINCT _cng_fid) counts sites."
    },
    {
      "name": "n_names",
      "type": "number",
      "description": "Number of different names recorded for this location_id over the record (1 to 3)."
    },
    {
      "name": "n_positions",
      "type": "number",
      "description": "Number of different coordinate pairs recorded for this location_id over the record (1 to 3). 54 locations have more than one; the point shown is the most recent."
    },
    {
      "name": "n_samples",
      "type": "number",
      "description": "Number of samples at this location over the whole record."
    },
    {
      "name": "first_sample",
      "type": "string",
      "description": "Date and time of the first sample at this location (UTC)."
    },
    {
      "name": "last_sample",
      "type": "string",
      "description": "Date and time of the most recent sample at this location (UTC)."
    },
    {
      "name": "n_enterococcus",
      "type": "number",
      "description": "Number of samples at this location with a Enterococcus value."
    },
    {
      "name": "n_clostridium",
      "type": "number",
      "description": "Number of samples at this location with a Clostridium perfringens value."
    },
    {
      "name": "n_water_temperature",
      "type": "number",
      "description": "Number of samples at this location with a water temperature value."
    },
    {
      "name": "n_salinity",
      "type": "number",
      "description": "Number of samples at this location with a salinity value."
    },
    {
      "name": "n_turbidity",
      "type": "number",
      "description": "Number of samples at this location with a turbidity value."
    },
    {
      "name": "n_ph",
      "type": "number",
      "description": "Number of samples at this location with a pH value."
    },
    {
      "name": "n_oxygen",
      "type": "number",
      "description": "Number of samples at this location with a dissolved oxygen value."
    },
    {
      "name": "n_oxygen_saturation",
      "type": "number",
      "description": "Number of samples at this location with a dissolved oxygen saturation value."
    },
    {
      "name": "geometry",
      "type": "geometry",
      "description": "Point at the location's most recent coordinates (WGS 84 / OGC:CRS84)."
    },
    {
      "name": "h8",
      "type": "uint64",
      "description": "H3 cell ID at resolution 8 (native resolution) containing the point."
    },
    {
      "name": "h0",
      "type": "int64",
      "description": "H3 cell ID at resolution 0, used as the partition key for hive-partitioned reads."
    }
  ]
}
