rawsList_filterDate: Date filtering for a list of _raws_timeseries_ objects

View source: R/rawsList_filterDate.R

rawsList_filterDateR Documentation

Date filtering for a list of raws_timeseries objects

Description

Subsets a list of raws_timeseries objects by date. This function always filters to day-boundaries.

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

  • "YYYYmmdd"

  • "YYYY-mm-dd"

Usage

rawsList_filterDate(
  rawsList = NULL,
  startdate = NULL,
  enddate = NULL,
  days = NULL,
  weeks = NULL,
  timezone = NULL
)

Arguments

rawsList

list of raws_timeseries object.

startdate

Desired start datetime (ISO 8601).

enddate

Desired end datetime (ISO 8601).

days

Number of days to include in the filterDate interval.

weeks

Number of weeks to include in the filterDate interval.

timezone

Olson timezone used to interpret dates.

Value

A list of subsets of the elements of the given list of raws_timeseries objects filtered by date.

Note

The returned data will run from the beginning of startdate until the beginning of enddatei.e. no values associated with enddate will be returned.

See Also

raws_filterDate

rawsList_filter

Examples


library(RAWSmet)

september_week1 <-
  example_cefaList %>%
  rawsList_filterDate(
    startdate = 20170901,
    enddate = 20170908,
    timezone = "America/Los_Angeles"
  )

head(september_week1)



MazamaScience/RAWSmet documentation built on May 6, 2023, 6:57 a.m.