get_area_pat: Get PurpleAir Timeseries (PAT) raw data and sensor meta data

Description Usage Arguments Value See Also Examples

View source: R/get_area_pat.R

Description

Iterate over a list of PurpleAir sensor IDs to extract sensor meta data and timeseries data given specified start and end dates

Usage

1
2
3
4
5
6
7
get_area_pat(
  id_list = ids,
  pas_input = pas_area,
  startdate = input_startdate,
  enddate = input_enddate,
  cols = c("created_at", "temperature", "humidity", "pm2.5_cf1", "pm2.5_atm")
)

Arguments

id_list

Character list; A list of PAS IDs

pas_input

PAS object; see get_area_pas.

startdate

Character; Date at which to start the collection (format: "YYYY-MM-DD")

enddate

Character; Date through which the data will be collected (format: "YYYY-MM-DD")

cols

Character list; List of variables of interest to keep. Site ID info will autmatically be collected

Value

List: dataframes of sensor meta info, and a dataframe of raw data for the variables of interest

See Also

pat_downloadParseRawData()

Other PA API functions: get_area_pas(), get_ids(), wrangle_data()

Examples

1
2
3
4
5
get_area_pat(
  id_list = c("6c18a7181a09037c_47107", "9f6643766cd4ba03_7572"),
  pas_input = (example(get_area_pas))$value,
  startdate = "2020-07-01", enddate = "2020-07-03"
)

gmcginnis/AirVizR documentation built on Dec. 20, 2021, 11:49 a.m.