Learn R Programming

openair

open source tools for air quality data analysis

openair is an R package developed for the purpose of analysing air quality data — or more generally atmospheric composition data. The package is extensively used in academia, the public and private sectors. The project was initially funded by the UK Natural Environment Research Council (NERC), with additional funds from the UK Department for Environment Food & Rural Affairs (Defra).

Part of the openair toolkit

| | |

Copy Link

Version

Install

install.packages('openair')

Monthly Downloads

4,035

Version

2.19.0

License

MIT + file LICENSE

Issues

Pull Requests

Stars

Forks

Maintainer

David Carslaw

Last Published

August 28th, 2025

Functions in openair (2.19.0)

corPlot

Correlation matrices with conditioning
conditionalQuantile

Conditional quantile estimates for model evaluation
aqStats

Calculate summary statistics for air pollution data by year
conditionalEval

Conditional quantile estimates with additional variables for model evaluation
calcFno2

Estimate NO2/NOX emission ratios from monitoring data
TaylorDiagram

Taylor Diagram for model evaluation with conditioning
calcPercentile

Calculate percentile values from a time series
TheilSen

Tests for trends using Theil-Sen estimates
binData

Bin data, calculate mean and bootstrap confidence interval in the mean
calendarPlot

Plot time series values in a conventional calendar format
importImperial

Import data from Imperial College London networks
importTraj

Import pre-calculated HYSPLIT 96-hour back trajectories
drawOpenKey

Scale key handling for openair
importMeta

Import monitoring site meta data for UK and European networks
importUKAQ

Import data from the UK Air Pollution Networks
cutData

Function to split data in different ways for conditioning
importEurope

Import air quality data from European database until February 2024
importADMS

CERC Atmospheric Dispersion Modelling System (ADMS) data import function(s) for openair
linearRelation

Linear relations between pollutants
importAURN

Import data from individual UK Air Pollution Networks
openair-package

openair: Tools for the Analysis of Air Pollution Data
polarDiff

Polar plots considering changes in concentrations between two time periods
modStats

Calculate common model evaluation statistics
percentileRose

Function to plot percentiles by wind direction
polarCluster

K-means clustering of bivariate polar plots
openColours

Pre-defined openair colours and definition of user-defined colours
polarAnnulus

Bivariate polarAnnulus plot
polarFreq

Function to plot wind speed/direction frequencies and other statistics
polarPlot

Function for plotting bivariate polar plots with smoothing.
mydata

Example air quality monitoring data for openair
selectRunning

Function to extract run lengths greater than a threshold
runRegression

Rolling regression for pollutant source characterisation.
splitByDate

Divide up a data frame by time
quickText

Automatic text formatting for openair
summaryPlot

Function to rapidly provide an overview of air quality data
selectByDate

Subset a data frame based on date
pollutionRose

Pollution rose variation of the traditional wind rose plot
smoothTrend

Calculate nonparametric smooth trends
scatterPlot

Flexible scatter plots
rollingMean

Calculate rolling mean pollutant values
trendLevel

Plot heat map trends
trajLevel

Trajectory level plots with conditioning
trajCluster

Calculate clusters for back trajectories
timeAverage

Function to calculate time averages for data frames
windRose

Traditional wind rose plot
timeVariation

Diurnal, day of the week and monthly variation
timeProp

Time series plot with categories shown as a stacked bar chart
timePlot

Plot time series
trajPlot

Trajectory line plots with conditioning