library(AirMonitor)
carmel <-
Carmel_Valley %>%
monitor_filterDate(20160801, 20160810)
# Create timeInfo object for this monitor
ti <- monitor_timeInfo(carmel)
# Subset the data based on day/night masks
data_day <- carmel$data[ti$day,]
data_night <- carmel$data[ti$night,]
# Build two monitor objects
carmel_day <- list(meta = carmel$meta, data = data_day)
carmel_night <- list(meta = carmel$meta, data = data_night)
# Plot them
carmel_day %>%
monitor_timeseriesPlot(
pch = 8,
col = "goldenrod",
shadedNight = TRUE
)
carmel_night %>%
monitor_timeseriesPlot(
add = TRUE,
pch = 16,
col = "darkblue"
)
Run the code above in your browser using DataLab