epa_createMonitorObject: Download and convert hourly EPA air quality data

Description Usage Arguments Value Note References Examples

View source: R/epa_createMonitorObject.R

Description

Convert EPA data into a ws_monitor object, ready for use with all monitor_~ functions.

Usage

1
2
3
4
5
epa_createMonitorObject(
  zipFile = NULL,
  zeroMinimum = TRUE,
  addGoogleMeta = TRUE
)

Arguments

zipFile

absolute path to monitoring data .zip file

zeroMinimum

logical specifying whether to convert negative values to zero

addGoogleMeta

logicial specifying wheter to use Google elevation and reverse geocoding services

Value

A ws_monitor object with EPA data.

Note

Before running this function you must first enable spatial data capabilities as in the example.

References

EPA AirData Pre-Generated Data Files

file format description

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
## Not run: 
# Fail gracefully if any resources are not available
try({

initializeMazamaSpatialUtils()
zipFile <- epa_downloadData(2016, "88101", downloadDir = '~/Data/EPA')
mon <- epa_createMonitorObject(zipFile, addGoogleMeta = FALSE)

}, silent = FALSE)

## End(Not run)

PWFSLSmoke documentation built on Nov. 23, 2021, 5:06 p.m.