airnow_loadAnnual: Load annual AirNow monitoring data

Description Usage Arguments Value See Also Examples

View source: R/airnow_loadAnnual.R

Description

Loads pre-generated .RData files containing annual AirNow data.

If dataDir is defined, data will be loaded from this local dirctory. Otherwise, data will be loaded from the monitoring data repository maintained by PWFSL.

The annual files loaded by this function are updated on the 15'th of each month and cover the period from the beginning of the year to the end of the last month.

For data during the last 45 days, use airnow_loadDaily().

For the most recent data, use airnow_loadLatest().

AirNow parameters include the following:

  1. PM2.5

Available AirNow RData and associated log files can be seen at: https://haze.airfire.org/monitoring/AirNow/RData

Usage

1
2
3
4
5
6
airnow_loadAnnual(
  year = NULL,
  parameter = "PM2.5",
  baseUrl = "https://haze.airfire.org/monitoring",
  dataDir = NULL
)

Arguments

year

Desired year (integer or character representing YYYY).

parameter

Parameter of interest.

baseUrl

Base URL for 'annual' AirNow data files.

dataDir

Local directory containing 'annual' data files.

Value

A ws_monitor object with AirNow data.

See Also

airnow_loadDaily

airnow_loadLatest

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## Not run: 
airnow_loadAnnual(2017) %>%
  monitor_subset(stateCodes='MT', tlim=c(20170701,20170930)) %>%
  monitor_dailyStatistic() %>%
  monitor_timeseriesPlot(style = 'gnats', ylim=c(0,300), xpd=NA)
  addAQIStackedBar()
  addAQILines()
  title("Montana 2017 -- AirNow Daily Average PM2.5")

## End(Not run)

PWFSLSmoke documentation built on July 8, 2020, 7:19 p.m.