sensor_join {AirSensor}R Documentation

Join airsensor objects from different time periods

Description

AirSensor objects are "joined end-to-end" so that time ranges are extended for all sensors that appear in either sensor1 and sensor2.

Only two airsensor objects at a time may be joined.

Usage

sensor_join(sensor1 = NULL, sensor2 = NULL)

Arguments

sensor1

An AirSensor object.

sensor2

An AirSensor object.

Value

An airsensor object containing all data from both incoming objects.

Examples


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

jan <- sensor_loadMonth("scaqmd", 202001)
feb <- sensor_loadMonth("scaqmd", 202002)
mar <- sensor_loadMonth("scaqmd", 202003)
apr <- sensor_loadMonth("scaqmd", 202004)

feb_mar <- sensor_join(feb, mar)
PWFSLSmoke::monitor_timeseriesPlot(feb_mar, style = 'gnats')

# Gaps in the time axis are filled with NA
feb_apr <- sensor_join(feb, apr)
PWFSLSmoke::monitor_timeseriesPlot(feb_apr, style = 'gnats')


[Package AirSensor version 1.0.8 Index]