A curated list of open technology projects to sustain a stable climate, energy supply, biodiversity and natural resources.

epair

Use R to get data from the Environmental Protection Agency API.
https://github.com/ropensci/epair

Category: Sustainable Development
Sub Category: Data Catalogs and Interfaces

Last synced: about 21 hours ago
JSON representation

Repository metadata

Use R to get data from the Environmental Protection Agency API

README.md

epair

DOI
R-CMD-check

A package designed to aid in getting data from the Environmental Protection Agency (EPA) API at
https://aqs.epa.gov/aqsweb/documents/data_api.html.

Overview

The epair package helps you determine what data you want and how to get that data from the EPA API.
It provides loaded in variables that help you navigate services in the API, and a simple way to query the data.

Broadly, you can explore possible calls by typing epair::get_ and seeing what autocomplete offers in R.
Most of these functions require a start and end date along with a geographical boundary type (like CBSA code or bounding box). For more details, we recommend looking at the help docs ?epair::get_[type]() for the function you're interested in using to see the exact required params.

Installation

You can download the package simply by using r-universe.

install.packages("epair", repos = "https://ropensci.r-universe.dev")

Alternativately, you can download the latest release from this repo using devtools.

devtools::install_github("ropensci/epair")

Or, download these files, and in your working directory run the following.

devtools::install("ropensci/epair")

epair depends on httr for making its data calls and rvest for creating the variables loaded in with the package. We recommend having httr installed (automatically taken care of through package dependencies), and only installing rvest if you're curious about how package variables were made.

Usage notes

Note that currently a single call to AQS allows for at maximum a single year's worth of data. You'll need to create separate calls to get multiple year's worth of data.

ropenaq

You may want to check out ropenaq instead depending on the goals behind your study. ropenaq is an R wrapper for accessing the OpenAQ API - see its website here. Here are a few differences:

  • epair will get data from a single source (EPA AQS API), while ropenaq will be more useful if you’re trying to compare data from different sources.

  • If you're interested in data for the US only, epair would be an appropriate choice. For more locations across the world, ropenaq would work better.

  • epair’s data source does offer more granularity than OpenAQ for US data. The EPA AQS API can give over 500 parameters/pollutants of interest (as opposed to OpenAQ’s 5), county level coverage, and unaggregated raw data. By default, OpenAQ will give aggregated data so if you're only interested in aggregations, then OpenAQ is the way to go.

Terms of Service

Make sure you also see the Usage Tips and Terms of Service associated with using this API at https://aqs.epa.gov/aqsweb/documents/data_api.html.


Owner metadata


GitHub Events

Total
Last Year

Committers metadata

Last synced: 7 days ago

Total Commits: 286
Total Committers: 3
Avg Commits per committer: 95.333
Development Distribution Score (DDS): 0.311

Commits in past year: 0
Committers in past year: 0
Avg Commits per committer in past year: 0.0
Development Distribution Score (DDS) in past year: 0.0

Name Email Commits
GLOrozcoM g****m@p****m 197
mmlawrence 6****e 86
ogilani o****i@g****m 3

Committer domains:


Issue and Pull Request metadata

Last synced: 2 days ago

Total issues: 0
Total pull requests: 34
Average time to close issues: N/A
Average time to close pull requests: 4 days
Total issue authors: 0
Total pull request authors: 2
Average comments per issue: 0
Average comments per pull request: 0.56
Merged pull request: 29
Bot issues: 0
Bot pull requests: 0

Past year issues: 0
Past year pull requests: 0
Past year average time to close issues: N/A
Past year average time to close pull requests: N/A
Past year issue authors: 0
Past year pull request authors: 0
Past year average comments per issue: 0
Past year average comments per pull request: 0
Past year merged pull request: 0
Past year bot issues: 0
Past year bot pull requests: 0

More stats: https://issues.ecosyste.ms/repositories/lookup?url=https://github.com/ropensci/epair

Top Issue Authors

Top Pull Request Authors

  • mmlawrence (17)
  • GLOrozcoM (17)

Top Issue Labels

Top Pull Request Labels

Score: 3.044522437723423