npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

us-county-airdata-trends

v2026.5.26

Published

U.S. county-level 5-year AirData emission trends derived from EPA AirData annual AQI summaries 2020-2024. Sensitivity-gated change class per county (decrease / increase / stable / insufficient_data) with facility-count gate, top-1-exclude robustness, and

Readme

us-county-airdata-trends

U.S. county-level 5-year AirData emission trends, derived from EPA AirData annual AQI summaries 2020-2024.

npm version DOI License: CC BY 4.0

Sensitivity-gated 5-year change classification for 994 US counties, with explicit display-hold flags for counties below the facility-count floor (368 counties) and the 4 petrochemical-corridor counties that surface a methodology-review notice instead of a trend value.

Produced by ZipCheckup Trend Layers v1. Display methodology underwent a 4-agent legal pre-build review (FTC compliance + defamation/stigmatization + statistical methodology + feeds feasibility) — see methodology page.


Install

npm install us-county-airdata-trends

Quick start

const airdata = require('us-county-airdata-trends');

// Look up a single county
const la = airdata.getCounty('06037');
// {
//   county_fips: '06037',
//   county_name: 'Los Angeles',
//   state: 'CA',
//   airdata_change_class: 'stable',
//   airdata_pct_change: -5.9,
//   cycles_used: 5,
//   facility_count: 331,
//   sensitivity_robust: null,
//   skip_reason: null,
//   source_attribution: 'EPA AirData annual AQI summaries 2020-2024',
//   petrochemical_corridor: false,
//   aqi_latest_year: 2024
// }

// All counties for a state
const texas = airdata.filterCounties({ state: 'TX' });

// Counties classified as decreasing (and display-eligible)
const decreasing = airdata.filterCounties({ changeClass: 'decrease', excludeSkipped: true });

// Display-eligible vs display-held — for methodology dashboards
const eligible = airdata.getDisplayEligibleCounties();
const held = airdata.getDisplayHeldCounties();

// Coverage metadata
console.log(airdata.meta);
// { generated: '2026-05-25', totalCounties: 994, coverage: { change_class_decrease: 67, ... }, ... }

Field schema

| Field | Type | Description | |-------|------|-------------| | county_fips | string | 5-digit US county FIPS code | | county_name | string | null | County name without "County" suffix | | state | string | null | 2-letter state abbreviation | | airdata_change_class | "decrease" \| "increase" \| "stable" \| "insufficient_data" | null | Sensitivity-gated 5-year class | | airdata_pct_change | number | null | Signed percent change between earliest and latest cycle | | cycles_used | integer | null | Number of reporting cycles (target 5, minimum 3) | | facility_count | integer | null | Distinct facilities in latest cycle (display gate ≥5) | | sensitivity_robust | boolean | null | True if direction stable when top-1 facility excluded | | skip_reason | string | null | "facility_count_below_threshold" | "petrochemical_corridor" | "cycles_below_threshold" | null | | source_attribution | string | Required attribution string for any public render | | petrochemical_corridor | boolean | True for 4 corridor counties (Harris TX, Calcasieu LA, Iberville LA, Kanawha WV) | | aqi_latest_year | integer | null | Latest reporting year included in window |

Full machine-readable schema: data/metadata.json.

Coverage (snapshot)

| Class | Counties | |-------|---------:| | decrease | 67 | | increase | 176 | | stable | 376 | | insufficient_data (display held) | 375 | | Total | 994 |

Of which display-held:

  • facility_count_below_threshold: 368
  • petrochemical_corridor: 4

Use cases

  • Journalism / civic data: county-level air-quality trend reference for explanatory reporting. Use getDisplayEligibleCounties() to filter out underpowered counties.
  • Research / academia: sensitivity-gated trend classification suitable for downstream regression as a county-level feature; raw airdata_pct_change available for the 994 counties with sufficient cycle coverage.
  • Embed / widget: county trend lookup for embeddable badges (see also API endpoint).

Methodology

Source: EPA AirData annual AQI summaries (annual_aqi_by_county_{YEAR}.zip), years 2020-2024, retrieved via https://aqs.epa.gov/aqsweb/airdata/download_files.html.

Pipeline:

  1. Aggregate facility-reported emissions to county rollups per year.
  2. Compute percent change between earliest and latest cycle.
  3. Apply sensitivity gates:
    • ≥3 reporting cycles in window
    • ≥5 reporting facilities in latest cycle
    • Top-1-exclude robustness: direction unchanged when largest facility excluded
  4. Bucket as decrease / increase / stable (|pct_change| < 10%) / insufficient_data.
  5. Hold display for 4 petrochemical-corridor counties pending methodology review (Harris TX 48201, Calcasieu LA 22019, Iberville LA 22047, Kanawha WV 54039) — see petrochemical_corridor boolean.

See full methodology: zipcheckup.com/methodology/airdata-trend/.

Caveats

  • This is facility-reported emissions data, not ambient air quality. The trend reflects what facilities reported to EPA — not what residents breathe.
  • AirData updates may reflect reporting methodology changes between cycles. Disclose this in any user-facing render.
  • 4 petrochemical-corridor counties surface as skip_reason: "petrochemical_corridor" with a methodology-review notice; do not silently treat them as insufficient_data.
  • This package is updated periodically. The meta.generated field surfaces the build date — check it before using for time-sensitive analysis.

License

CC BY 4.0. Free to use with attribution.

Citation

Akulov, A. (2026). U.S. County AirData 5-Year Emission Trends [Data set].
ZipCheckup. https://doi.org/10.5281/zenodo.20382474

Or BibTeX:

@dataset{zipcheckup_us_county_airdata_trends,
  author    = {Akulov, Artem},
  title     = {U.S. County AirData 5-Year Emission Trends},
  year      = {2026},
  publisher = {ZipCheckup},
  doi       = {10.5281/zenodo.20382474},
  url       = {https://doi.org/10.5281/zenodo.20382474}
}

Related

Source repository

github.com/artakulov/waterbyzipcode (this package lives under packages/us-county-airdata-trends/).