sensor_load: Load hourly-aggregated PurpleAir data

Description Usage Arguments Value See Also Examples

View source: R/sensor_load.R

Description

A pre-generated airsensor object will be loaded for the given time interval. Archived data for SCAQMD sensors go back to January, 2018.

Dates can be anything that is understood by lubrdiate::parse_date_time() including either of the following recommended formats:

By default, the current week is loaded.

Usage

1
2
3
4
5
6
7
sensor_load(
  collection = "scaqmd",
  startdate = NULL,
  enddate = NULL,
  days = 7,
  timezone = "America/Los_Angeles"
)

Arguments

collection

Name associated with the collection.

startdate

Desired start datetime (ISO 8601).

enddate

Desired end datetime (ISO 8601).

days

Number of days of data to include (7 or 45).

timezone

Timezone used to interpret start and end dates.

Value

An object of class "airsensor".

See Also

sensor_loadMonth

sensor_loadYear

Examples

1
2
3
4
5
6
library(AirSensor)

setArchiveBaseUrl("http://data.mazamascience.com/PurpleAir/v1")

sensor_load("scaqmd", 20200411, 20200521) %>%
  PWFSLSmoke::monitor_timeseriesPlot(style = 'gnats')

AirSensor documentation built on March 13, 2021, 1:07 a.m.